1 | import React from 'react';
|
2 | import { CurveFactory } from 'victory-vendor/d3-shape';
|
3 | import { LayoutType, PresentationAttributesWithProps } from '../util/types';
|
4 | export type CurveType = 'basis' | 'basisClosed' | 'basisOpen' | 'bumpX' | 'bumpY' | 'bump' | 'linear' | 'linearClosed' | 'natural' | 'monotoneX' | 'monotoneY' | 'monotone' | 'step' | 'stepBefore' | 'stepAfter' | CurveFactory;
|
5 | export interface Point {
|
6 | x: number;
|
7 | y: number;
|
8 | }
|
9 | interface CurveProps {
|
10 | className?: string;
|
11 | type?: CurveType;
|
12 | layout?: LayoutType;
|
13 | baseLine?: number | Array<Point>;
|
14 | points?: Array<Point>;
|
15 | connectNulls?: boolean;
|
16 | path?: string;
|
17 | pathRef?: (ref: SVGPathElement) => void;
|
18 | }
|
19 | export type Props = Omit<PresentationAttributesWithProps<CurveProps, SVGPathElement>, 'type' | 'points'> & CurveProps;
|
20 | type GetPathProps = Pick<Props, 'type' | 'points' | 'baseLine' | 'layout' | 'connectNulls'>;
|
21 | export declare const getPath: ({ type, points, baseLine, layout, connectNulls, }: GetPathProps) => string | null;
|
22 | export declare const Curve: React.FC<Props>;
|
23 | export {};
|