jlmakes / scrollreveal

Animate elements as they scroll into view.
https://scrollrevealjs.org/
22.35k stars 2.26k forks source link

Sequencer like on demo site? #367

Closed discoveryjames closed 7 years ago

discoveryjames commented 7 years ago

What version are you running on the demo website?

If you use a interval reveal using the version on the github, it continues to reveal all regardless of whether they are visible or not, whereas if you use the version on your demo website it works as expected (interval reveals as they become visible).

Great library by the way!

jlmakes commented 7 years ago

Every ScrollReveal instance has a version property, so can always determine what version is in use by entering this into the console:

ScrollReveal().version

The demo is running 4.0.0-beta.2

"If you use a interval reveal using the version on the github, it continues to reveal all regardless of whether they are visible or not..."

This is a known limitation of the v3.x sequencer, and one of the main feature improvements made in version 4. Getting it to "work as expected" has been surprisingly difficult, but it’s very close!

discoveryjames commented 7 years ago

Ahh, thanks for the quick response!

Yeah, it's very close. The only issues I found are that if you refresh the page already scrolled or scroll too quick it doesn't reveal the elements. Other than that it seems to work very well!

jlmakes commented 7 years ago

"Scrolling too fast" has been solved since 4.0.0-beta.4 (#341), but there’s still a bug when using options.reset preventing me from dropping the beta tag.

4.0.0-beta.10 will be out soon, with another sequencer refactor and hopefully less bugs—so I can officially release 4.0! I’ve written your username down, so I’ll make sure to ping you when it’s ready.

discoveryjames commented 7 years ago

@jlmakes thanks for letting me know!

I've just compared the two versions, an issue seems to prevent elements revealing in quite a few different scenarios, which worked fine on the previous version.

Would it be useful for you if I setup a demo of our website with beta 9 and beta 10, to that you can see?

jlmakes commented 7 years ago

I knew I wasn’t finished, but I was hoping it’d hold up a bit better than this... I too have found issues with the beta.10 sequencer. (This is what I get for deciding to release at 5am instead of going to bed.)

Luckily, a lot of other stuff I was working on in beta.10 does appear to be functioning well—so again, it comes down to sequencer logic being a real pain in the arse.

I appreciate the offer @discoveryjames, but your willingness to help me test is more than enough. Just give me another day or two to patch up the sequencer for beta.11.

discoveryjames commented 7 years ago

@jlmakes sounds good, let me know and I'll test it for you!

jlmakes commented 7 years ago

Alright, beta.11 is out @discoveryjames, which should score well across the board.

There’s actually one edge case I want to address (that I won’t mention, teehee)... so I think there‘s a beta.12 coming before I drop the beta tag, but let me know what you find! 🍻

discoveryjames commented 7 years ago

I still seem to get similar issues. I'll have a mess about later see if I can find anything which is causing the issues, but a few elements fail to reveal.

I have reverted back to beta.9 for now, which seems to resolve the issues. I'll try and work it out and give you the heads up!

jlmakes commented 7 years ago

The reason all these issues stem from sequences being out of view, is because options.reset is very popular and needs to work sequenced elements.

Update 8/12 @discoveryjames I’ve had some time to work on this; the latest beta.13 is performing very well in my tests. (It’s live on the demo site.) Please let me know how things are working for you!

discoveryjames commented 7 years ago

@jlmakes I have completed some testing on beta.14 this morning, and it seems to be the best yet! Going to try it on a larger screen later, as I have previously been testing on that.

Seems to be just about there though!