Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: shift + wheel scroll doesn't work #28

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

prayinforrain
Copy link

Hi, thank you for such a nice package. I really appreciate it 😁

However I noticed that horizontal scroll with mouse wheel(shift + wheelScroll) doesn't make any scroll, even if there's a handler for it. So I made a small commit to fix it.

I hope this PR will help..

*Tested on MacOS Ventura 13.4, Chrome

@fallenleavesguy
Copy link

@prayinforrain your new code is work on osx system.but on window, it should use deltaY.

I can offer a demo code

        const isMac = /Mac/i.test(navigator.userAgent);

        let dx = isScrollingHorizontally ? (isMac ? deltaX : deltaY) : deltaX;

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants