///
import { AnimationItem, AnimationConfigWithData, SVGRendererConfig } from 'lottie-web';
export declare const LOTTIE_RENDERERS: readonly ["svg", "canvas"];
type LottiOptions = Pick;
export interface LottieProps extends LottiOptions {
/**
* 自定义 class
*/
className?: string;
/**
* 动画数据对象
*/
animationData?: AnimationConfigWithData['animationData'];
/**
* 渲染器
*/
renderer?: (typeof LOTTIE_RENDERERS)[number];
/**
* 是否加载后自动开始播放
*/
autoplay?: boolean;
/**
* 是否循环播放
*/
loop?: boolean;
/**
* 播放速度
*
* - `1` 正常速度
* - `-1` 反向播放,正常速度
* - 数字越大,速率越大
*/
speed?: number;
/**
* @private 预留必要时公开
* https://github.com/airbnb/lottie-web/wiki/Renderer-Settings
*/
rendererSettings?: SVGRendererConfig;
/**
* @private 预留必要时公开
* you can specify a different root path for external assets path instead of the images folder
*/
assetsPath?: AnimationConfigWithData['assetsPath'];
}
/**
* Lottie 对外实例句柄(经 ref 调用)
*/
export interface LottieHandle {
play: () => void;
stop: () => void;
pause: () => void;
togglePause: () => void;
destroy: () => void;
readonly animation: AnimationItem | null;
}
export declare const Lottie: import("react").ForwardRefExoticComponent>;
export {};