Animation on scroll

Here the animation starts when in viewport and reverses when out of viewport

alt-text