UNPKG

1.41 kBTypeScriptView Raw
1import type { StyleProps, AnimatableValue, AnimationObject, Animation, Timestamp, AnimationCallback, AnimatedStyle } from '../commonTypes';
2export interface HigherOrderAnimation {
3 isHigherOrder?: boolean;
4}
5export type NextAnimation<T extends AnimationObject> = T | (() => T);
6export interface ClampAnimation extends Animation<ClampAnimation>, HigherOrderAnimation {
7 current: AnimatableValue;
8}
9export interface DelayAnimation extends Animation<DelayAnimation>, HigherOrderAnimation {
10 startTime: Timestamp;
11 started: boolean;
12 previousAnimation: DelayAnimation | null;
13 current: AnimatableValue;
14}
15export interface RepeatAnimation extends Animation<RepeatAnimation>, HigherOrderAnimation {
16 reps: number;
17 startValue: AnimatableValue;
18 toValue?: AnimatableValue;
19 previousAnimation?: RepeatAnimation;
20}
21export interface SequenceAnimation extends Animation<SequenceAnimation>, HigherOrderAnimation {
22 animationIndex: number;
23}
24export interface StyleLayoutAnimation extends HigherOrderAnimation {
25 current: StyleProps;
26 styleAnimations: AnimatedStyle<any>;
27 onFrame: (animation: StyleLayoutAnimation, timestamp: Timestamp) => boolean;
28 onStart: (nextAnimation: StyleLayoutAnimation, current: AnimatedStyle<any>, timestamp: Timestamp, previousAnimation: StyleLayoutAnimation) => void;
29 callback?: AnimationCallback;
30}
31//# sourceMappingURL=commonTypes.d.ts.map
\No newline at end of file