@lynksen/react-gsap-utils
Version:
Collection of zero-config, drop-in utilities to animate React elements and components using GSAP Tween animation props.
24 lines (20 loc) • 735 B
TypeScript
import React from 'react';
type AnimateRevealProps = {
children: React.ReactNode;
YOffset?: number;
from?: any;
className?: string;
childClassName?: string;
onComplete?: () => void;
onStart?: () => void;
debug?: boolean;
};
declare function AnimateOnScroll({ children, YOffset, from, className, childClassName, onComplete, onStart, debug, }: AnimateRevealProps): React.JSX.Element;
interface AnimateOnMountProps {
children: React.ReactNode;
mounted: boolean;
className?: string;
fromTo?: [gsap.TweenVars, gsap.TweenVars];
}
declare function AnimateOnMount({ children, mounted, className, fromTo, }: AnimateOnMountProps): React.JSX.Element;
export { AnimateOnMount, AnimateOnScroll };