home block "snap" function issues on ipad and mobile
URL to the page in question:
http://www.vilhelmstokstad.com
-
Hi again!
Thanks for all the help so far.
There is a function that makes the home blocks “pop” in to place when scrolling the home screen. This is a very nice function but i doesn’t work very good on mobile and ipad. it seems to snap back to home blocks that you already passed by, a bit too often. is there a way to disable it on mobile or make it more accurate?
Thanks
Vilhelm,
I believe we can turn that “snap to” off for smaller devices with a bit of editing. Here’s what to do:
- Go to the Appearance section in your WordPress dashboard and choose Edit.
- From the list of files on your right, choose custom-js.php
- Find this section:
// Window Scroll Options
jQuery(document).ready(function(){
jQuery('.window').windows({
snapping: true,
snapSpeed: 200,
snapInterval: 500,
onScroll: function(scrollPos){
// scrollPos:Number
},
onSnapComplete: function($el){
// after window ($el) snaps into place
},
onWindowEnter: function($el){
// when new window ($el) enters viewport
}
})
});
and replace it with this:
Be sure to copy that code directly from the support site and not the notification email.
- Save your changes.
See if that won’t remove the effect from screens 1024 pixels wide and smaller. Let me know if you run into trouble.
Have a great day,
Bill
That did it! thanks a lot!
Glad to hear that one worked. Thanks again.
- The topic ‘home block "snap" function issues on ipad and mobile’ is closed to new replies.