1 | import { PathCommand } from '../../../dependents';
|
2 | import { ShapeVertices } from '../../../interface';
|
3 | /**
|
4 | * @ignore
|
5 | * 分割数据,用于处理在一组点数据中,y 对应的数值存在 null/undefined/NaN 的情况
|
6 | * 应用于折线图、区域图以及路径图
|
7 | *
|
8 | * ```typescript
|
9 | * // return [[{x: 1, y: 2}, {x: 3, y: 3}]]
|
10 | * getPathPoints([{x: 1, y: 2}, {x: 2, y: null}, {x: 3, y: 3}], true);
|
11 | * // return [[{x: 1, y: 2}], [{x: 3, y: 3}]]
|
12 | * getPathPoints([{x: 1, y: 2}, {x: 2, y: null}, {x: 3, y: 3}], false);
|
13 | * // return [[[{ x: 1, y: 10 }, { x: 2, y: 2 }], [{ x: 9, y: 34 }, { x: 1, y: 1 }]]]
|
14 | * getPathPoints([
|
15 | * [{ x: 1, y: 10 }, { x: 2, y: 2 }],
|
16 | * [{ x: 4, y: 2 }, { x: 8, y: NaN }],
|
17 | * [{ x: 9, y: 34 }, { x: 1, y: 1 }],
|
18 | * ], true);
|
19 | * ```
|
20 | *
|
21 | * @param points 要进行处理点集合
|
22 | * @param connectNulls 是否连接空值数据
|
23 | * @param showSinglePoint 是否展示孤立点
|
24 | * @returns 返回处理后的点集合
|
25 | */
|
26 | export declare function getPathPoints(points: ShapeVertices, connectNulls?: boolean, showSinglePoint?: boolean): any[];
|
27 | /**
|
28 | * 获取小提琴图的边界 path
|
29 | * @param points
|
30 | * @returns
|
31 | */
|
32 | export declare function getViolinPath(points: ShapeVertices): PathCommand[];
|
33 | /**
|
34 | * 获取小提琴图 平滑的边界 path
|
35 | * @param points
|
36 | * @returns
|
37 | */
|
38 | export declare function getSmoothViolinPath(points: ShapeVertices): PathCommand[];
|