UNPKG

react-native-reanimated

Version:

More powerful alternative to Animated library for React Native.

21 lines (20 loc) 717 B
import type { Animation, AnimationCallback, AnimationObject, AnimatableValue, Timestamp } from '../commonTypes'; interface DecayConfig { deceleration?: number; velocityFactor?: number; clamp?: number[]; velocity?: number; } export interface DecayAnimation extends Animation<DecayAnimation> { lastTimestamp: Timestamp; startTimestamp: Timestamp; initialVelocity: number; velocity: number; current: AnimatableValue; } export interface InnerDecayAnimation extends Omit<DecayAnimation, 'current'>, AnimationObject { current: number; } type withDecayType = (userConfig: DecayConfig, callback?: AnimationCallback) => number; export declare const withDecay: withDecayType; export {};