scrolldeck.js
scrolldeck.js copied to clipboard
Remove space scroll
Hi,
I love ScrollDeck, but I've a little question.
How can I avoid the scroll down when I hit the space key?
Thanks a lot :)
yes.. i have the same question... any answer ? love the scrolldeck plugin..thx john polacek
i found fix for my case, actually i have a textarea inside the slide, the problem is when i hit space while focusing in the textarea the page scrolling to the next slide, now i edit the js file in line127
else if ((e.keyCode == 39 || e.keyCode == 32 || e.keyCode == 40) && currIndex != slides.length-1) { scrollToSlide(getNextScrollpoint()); }
and remove the || e.keyCode == 32 line. it did works for me when i'm focus or writing in the textarea.
Yes, that's what you can do. Thanks!
Hello, I haven't tried it yet but I need one more tip similar to this one.
First I need to disable scrolling unless an event occurs (like a click) on a button. (Scrollbars are gone with the html {overflow:hidden}), the spacebar and arrow keys solution is written from gunaifitm85 above me (?).
Cause of that I need to have specific sized div tags so that every .slide div takes up 100% of the screen without the user being able to jump to the next one unless that event (as mentioned above).
Could you please point me at some direction? Thank you