Fix index animations
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
2020-04-06 22:53:46 +02:00
parent f414457172
commit 1a05c35fc8
5 changed files with 48 additions and 16 deletions

View File

@@ -13,7 +13,7 @@ export const animateIn = (scope, init) => {
translateY: ['100%', 0],
easing: 'easeOutQuart',
duration: 1000,
delay: anime.stagger(40),
delay: anime.stagger(40, { start: init ? 0 : animDelay }),
autoplay: false
})
@@ -21,12 +21,6 @@ export const animateIn = (scope, init) => {
const title = ScrollOut({
once: true,
targets: scope,
onShown: () => {
if (init) {
letters.restart()
} else {
setTimeout(() => letters.restart(), animDelay)
}
}
onShown: () => letters.restart()
})
}