-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathanimation.js
88 lines (82 loc) · 1.54 KB
/
animation.js
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
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
export const pageAnimation = {
hidden: {
opacity: 0,
y: 300,
},
show: {
opacity: 1,
y: 0,
transition: {
duration: 0.5,
when: "beforeChildren",
staggerChildren: 0.25,
},
},
exit: {
opacity: 0,
transition: {
duration: 0.5,
},
},
};
export const titleAnim = {
hidden: { y: 200 },
show: {
y: 0,
transition: { duration: 0.75, ease: "easeOut" },
},
};
export const fade = {
hidden: { opacity: 0 },
show: {
opacity: 1,
transition: { ease: "easeOut", duration: 0.75 },
},
};
export const photoAnim = {
hidden: { scale: 1.5, opacity: 0 },
show: {
scale: 1,
opacity: 1,
transition: {
ease: "easeOut",
duration: 0.75,
},
},
};
export const lineAnim = {
hidden: { width: "0%" },
show: {
width: "100%",
transition: { duration: 1 },
},
};
export const slider = {
hidden: { x: "-130%", skew: "45deg" },
show: {
x: "100%",
skew: "0deg",
transition: { ease: "easeOut", duration: 1 },
},
};
export const sliderContainer = {
hidden: { opacity: 1 },
show: { opacity: 1, transition: { staggerChildren: 0.15, ease: "easeOut" } },
};
export const scrollReveal = {
hidden: { opacity: 0, scale: 1.2, transition: { duration: 0.5 } },
show: {
opacity: 1,
scale: 1,
transition: {
duration: 0.5,
},
},
};
// export const swoopAdoop = {
// hidden: { width: "-20%", transition: { duration: 1 } },
// show: {
// width: "100%",
// transition: { ease: "easeOut", duration: 1 },
// },
// };