scrollTop is not cloned

#41 · closed · 1 comments

View on GitHub ↗

callumlocke

If you're transitioning from/to an element with overflow:auto/scroll, and which the user has already scrolled before ramjetting, this causes an ugly jump at the beginning/end of the transition, breaking the illusion. It's also possible that it's not the outer element but some descendent that is scrollable... So to fix this properly you'd need to walk through all descendent elements and copy over the scrollTop for each one (if it's not 0). Not sure how feasible that is.

Comments

sithmel

I would suggest to use the overrideClone function for creating a clone that includes the scroll. I am closing it but open to further discussion ...