-
Notifications
You must be signed in to change notification settings - Fork 48
/
index.d.ts
42 lines (36 loc) · 1.01 KB
/
index.d.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
declare module "lottie-react-web" {
import * as React from "react";
import { AnimationConfig } from "lottie-web";
export interface LottieOptions {
animationData: any;
loop?: boolean;
autoplay?: boolean;
rendererSettings?: AnimationConfig["rendererSettings"];
}
export interface LottieEventListener {
eventName: string;
callback: () => void;
}
export interface LottileAnimationControl {
[property: string]: [number, number];
}
export interface LottieProps {
options: LottieOptions;
animationControl?: LottileAnimationControl;
height?: string | number;
width?: string | number;
isStopped?: boolean;
isPaused?: boolean;
speed?: number;
segments?: number[];
forceSegments?: boolean;
direction?: 1 | -1;
ariaRole?: string;
ariaLabel?: string;
title?: string;
// Not documented
style?: React.CSSProperties;
eventListeners?: LottieEventListener[];
}
export default class Lottie extends React.Component<LottieProps> {}
}