skrollr-menu
skrollr-menu copied to clipboard
Fixed-positioning and skrollr menu don't work together
So I have a page based on the The "main" example, and as I did not want a continue scroll but stopping at some point to do animations etc I am using the css fixed-positioning.css..
It all works nicely but having the fixed positions makes the skrollr-menu to stop working as it does when not using fixed-positioning.css.
It makes my menu items to scroll to half of the items or no scroll the page at all, or just a portion.... you have to click the menu item few times before this gets the anchor link to the top any idea how to solve this?
Thanks a lot
If I understand you correctly, that's what data-menu-top is for.
Hi Alexander,
I'm severally confused, I am not sure how to use the data-menu-top.... could you point me into an example? It might be that i'm not implementing this right and that this is not an issue.
Thanks
Here's an example page
https://github.com/Prinzhorn/skrollr-menu/blob/master/index.html http://prinzhorn.github.io/skrollr-menu/
@fritoebola I was experiencing the exact same issues as you.
Like @Prinzhorn says if you add data-menu-top="325p" Accommodations
it will scroll 350% down the page. You will want that to match your last data-???p sequence on your container you are scrolling to.
For instance on my page I have the following:
So i want my data-menu-top attribute from the link to match transform:translate(0,0%) so it is set to 325p.
data-menu-top is either broken or has no example
data-menu-top is either broken or has no example
http://prinzhorn.github.io/skrollr-menu/
Sorry that this is late @fritoebola but the way I managed to get around this issue was using
var s = skrollr.init({
edgeStrategy: 'reset'
});
Using the reset causes the element to revert back to it's original position: relative/static/absolute/whatever before the first keyframe and after the last. There is still some slight odd behavior (such as you described) when it comes to going to adjacent slides or clicking the menu item for the slide it is currently on. Will report back when I figure out how to fix that.
Well, a good tip is never late. We can all always use this on future projects. Cheers P.