UNPKG

2.08 kBTypeScriptView Raw
1import { Component, ComponentType } from '@antv/f-engine';
2import { Point, Tick } from './gaugeView';
3export interface GaugeProps {
4 startAngle?: number;
5 endAngle?: number;
6 tickCount?: number;
7 tickOffset?: number | string;
8 tickLength?: number | string;
9 r?: number | string;
10 r0?: number | string;
11 center?: Point;
12 ticks?: Tick[];
13 percent: number;
14}
15declare const withGauge: <IProps extends GaugeProps = GaugeProps>(View: ComponentType<IProps>) => {
16 new <P extends IProps = IProps>(props: P, context?: import("@antv/f-engine").IContext, updater?: import("@antv/f-engine/es/component/updater").Updater<import("@antv/f-engine").IState>): {
17 render(): import("@antv/f-engine").JSX.Element;
18 props: P;
19 state: import("@antv/f-engine").IState;
20 context: import("@antv/f-engine").IContext;
21 refs: {
22 [key: string]: Component<import("@antv/f-engine").IProps, import("@antv/f-engine").IState>;
23 };
24 updater: import("@antv/f-engine/es/component/updater").Updater<import("@antv/f-engine").IState>;
25 container: import("@antv/g-lite").Group;
26 layout: import("@antv/f-engine").LayoutProps;
27 children: import("@antv/f-engine/es/canvas/vnode").VNode | import("@antv/f-engine/es/canvas/vnode").VNode[];
28 isMounted: boolean;
29 animate: boolean;
30 animator: import("@antv/f-engine/es/canvas/render/animator").default;
31 destroyed: boolean;
32 _vNode: import("@antv/f-engine/es/canvas/vnode").VNode;
33 willMount(): void;
34 didMount(): void;
35 shouldUpdate(_nextProps: P): boolean;
36 willReceiveProps(_props: P, _context?: import("@antv/f-engine").IContext): void;
37 willUpdate(): void;
38 didUpdate(): void;
39 willUnmount(): void;
40 didUnmount(): void;
41 setState(partialState: import("@antv/f-engine").IState, callback?: () => void): void;
42 forceUpdate(callback?: () => void): void;
43 setAnimate(animate: boolean): void;
44 destroy(): void;
45 };
46};
47export default withGauge;