MCPcopy Create free account
hub / github.com/api-platform/website / fadeIn

Function fadeIn

pwa/hooks/con/useAnimation.tsx:8–18  ·  view source on GitHub ↗
(element: gsap.TweenTarget, duration: number, delay: number)

Source from the content-addressed store, hash-verified

6export type DirectionType = "bottom" | "left" | "right" | "top" | "scale";
7
8const fadeIn = (element: gsap.TweenTarget, duration: number, delay: number) => {
9 gsap.to(element, {
10 opacity: 1,
11 duration,
12 x: 0,
13 y: 0,
14 scale: 1,
15 ease: "power4.out",
16 delay,
17 });
18};
19
20const fadeOut = (
21 element: gsap.TweenTarget,

Callers 1

useAnimationFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected