wix-style-react
Version:
wix-style-react
77 lines • 2.75 kB
TypeScript
export default SparklineChart;
/** SparklineChart */
declare class SparklineChart extends React.PureComponent<any, any, any> {
constructor(props: any);
randomComponentId: string;
chartContext: {};
svgRef: React.RefObject<any>;
componentRef: React.RefObject<any>;
state: {
hoveredLabel: null;
};
_shouldShowTooltip: () => any;
_useCreateContext: () => {
margin: {
top: number;
right: number;
bottom: number;
left: number;
};
width: any;
height: any;
innerTop: number;
innerLeft: number;
innerBottom: number;
innerWidth: number;
innerHeight: number;
data: any;
xScale: any;
yScale: any;
highlightedStartingIndex: any;
highlightedEndingIndex: any;
lineGenerator: any;
areaGenerator: any;
color: any;
};
_getLabelAt: (data: any, position: any) => any;
_getValueAt(data: any, position: any): any;
_getValues: (data: any) => any;
_getLabels: (data: any) => any;
_drawSparkline: () => void;
_areDatesEqual(date1: any, date2: any): boolean;
_getLineColorId(dataSet: any, componentId: any): string;
_getAreaMaskId(componentId: any): string;
_drawLines: (dataContainer: any) => void;
_updateLines: (container: any) => void;
_updateComponent: (container: any, className: any, fncUpdater: any) => void;
componentDidMount(): void;
componentDidUpdate(prevProps: any): void;
_updateContext(): void;
render(): React.JSX.Element;
}
declare namespace SparklineChart {
let displayName: string;
namespace propTypes {
let dataHook: PropTypes.Requireable<string>;
let className: PropTypes.Requireable<string>;
let width: PropTypes.Requireable<number>;
let height: PropTypes.Requireable<number>;
let data: PropTypes.Validator<(PropTypes.InferProps<{
label: PropTypes.Requireable<Date>;
value: PropTypes.Requireable<number>;
}> | null | undefined)[]>;
let color: PropTypes.Requireable<string>;
let highlightedStartingIndex: PropTypes.Requireable<number>;
let highlightedEndingIndex: PropTypes.Requireable<number>;
let getTooltipContent: PropTypes.Requireable<(...args: any[]) => any>;
let onHover: PropTypes.Requireable<(...args: any[]) => any>;
let animationDuration: PropTypes.Requireable<number>;
}
namespace defaultProps {
let animationDuration_1: number;
export { animationDuration_1 as animationDuration };
}
}
import React from 'react';
import PropTypes from 'prop-types';
//# sourceMappingURL=SparklineChart.d.ts.map