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(core): On mouse pointer click move the scrollbar to correct position #667

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

Conversation

mlipovaca
Copy link

Issue:
Scrollbar is not moving to mouse position when clicked on the track.

What is done to fix it:
Scrollbar is now moving by the calculation to specific (exact) mouse position when clicked on the track.

@mlipovaca
Copy link
Author

Please if you can review it @Grsmto

@Grsmto
Copy link
Owner

Grsmto commented Apr 15, 2023

Hi @mlipovaca thanks for your contribution. The default behaviour on most browsers seems to be that it does not scroll where the user click but rather scroll down 1 viewport height, which is the behaviour of SimpleBar at the moment.
One difference is that on the default scrollbar you can long press to scroll more (not supported by SimpleBar but could be).
So I think we want to stick to the default behaviour as much as possible.
Do you have any example of the behaviour you are describing and how you came up to want it that way? Thanks.

@mlipovaca
Copy link
Author

Hi @Grsmto, thanks for the reply. Here're the differences when you "hold" the click on the navigation bar track and on default browser, it'll keep scrolling until it reaches it, but on simplebar it moves only once and that's it.

Reference:

  1. Default browser - https://chicksgold.gyazo.com/c423973d0689bebe71beeef1a5d98c5c
  2. Simplebar browser - https://chicksgold.gyazo.com/aec8fa411a33f42af2f74ce66dfb12f4

@mlipovaca
Copy link
Author

Any words on this @Grsmto ?

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