UNPKG

@visactor/vrender-animate

Version:

This module provides a graph-based animation system for VRender.

35 lines (34 loc) 1.31 kB
import type { IGraphic, IGroup, IAnimate, IStep, EasingType } from '@visactor/vrender-core'; import { ACustomAnimate } from './custom-animate'; interface IAnimationParameters { width: number; height: number; group: IGroup; elementIndex: number; elementCount: number; view: any; } type TypeAnimation<T extends IGraphic> = (graphic: T, options: any, animationParameters: IAnimationParameters) => { from?: { [channel: string]: any; }; to?: { [channel: string]: any; }; }; export declare class GrowHeightIn extends ACustomAnimate<Record<string, number>> { valid: boolean; constructor(from: null, to: null, duration: number, easing: EasingType, params?: any); onBind(): void; onEnd(cb?: (animate: IAnimate, step: IStep) => void): void; onUpdate(end: boolean, ratio: number, out: Record<string, any>): void; } export declare const growHeightOut: TypeAnimation<IGraphic>; export declare class GrowHeightOut extends ACustomAnimate<Record<string, number>> { valid: boolean; constructor(from: null, to: null, duration: number, easing: EasingType, params?: any); onBind(): void; onEnd(cb?: (animate: IAnimate, step: IStep) => void): void; onUpdate(end: boolean, ratio: number, out: Record<string, any>): void; } export {};