Sorry been messing around in the codepen so its a little messy.
I managed to get the same effect as you showed in the codepen but that's not what im after. I only want the animation to happen once, not every time it leaves or enters the element. I know the property once:true exists but then it only works for onEnter and the animation will not work if i refresh the page on the bottom and scroll upp.
So for example, when i enter the page from top to bottom it works properly, it animates each element once and thats it. But if i refresh at the bottom or middle of the page it triggers all the animation above as im gussing it assumes they have already entered the viewport somehow? But i want those animations to not be triggered until i actual get there with scroll? And the animation should only happen once on the element (.box) in our case.