-
Notifications
You must be signed in to change notification settings - Fork 2.5k
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
Add option to use scrollBehavior:smooth to fix choppy firefox scroll when resistFingerprinting is enabled #3701
base: master
Are you sure you want to change the base?
Conversation
Yep ran into this issue too, could this please be merged? :) |
@kamkudla I compiled your change in an unpacked version of the latest version of vimium and I am still getting choppy scrolling after selecting the |
@kabeersvohra It's probably due to the new KV pair not getting set to storage unless you refresh 1) Try |
@kamkudla yes sorry about that, this was my bad that it was clashing with the normal vimium that I had installed already. However when I try and hold down j now it moves down for a small amount, stops for half a second and then scrolls but still in a slightly jittery manner, it is much smoother than the normal setting but still not the same as the original smooth scrolling. Perhaps this is a limitation of the 'scrollBehaviourSmooth' setting? |
@kabeersvohra Change the scroll step size in the Vimium options to something greater like 100px or to your preference and save. It could also be your system is resource constrained, close some tabs and check again. It's scrolling smoothly on my end with the key pressed. |
Thanks for the help, will have another go tomorrow and Let you know |
Sorry didn't get back to you, I am still having the same issue after changing the pixel size and trying on 3 different devices, are you getting exactly the same behaviour as the normal smooth scrolling with fingerprinting on? |
Go to the Vimium options page and open up the console - what does |
Does your version require |
During my tests on Firefox 80 x64, Win 10, with system animation enabled, it works only when I disabled Use smooth scrolling and enabled "alternative smooth scroll", and there's still a difference: the Vimium Options page scrolled much slower in such a case, compared with "the original smooth scrolling + not resist fingerprinting". BTW, my working around for this issue is to assume a small time period of 17ms, when two timestamps from requestAnimationFrame are same: |
@kabeersvohra Sounds like it could be a system issue. Behavior on my end is normal. I am on MacOS running Firefox Developer Edition 83.0b7. It could be the calling of vimium/content_scripts/scroller.js Line 64 in 00228e0
From
|
@gdh1995 Yes, vimium/content_scripts/scroller.js Lines 224 to 229 in 00228e0
Which then performs a native JS Thanks for sharing your solution. I'll have to study the sequence a bit further. Is your scroll logic in your fork fundamentally different than this one? |
My animation logic is forked from this Vimium, and the scrolling step algorithm has no changes. On my win10 laptop/PC, both Chrome and Firefox will make scrolling very slow, if |
Thanks for the PR. I think this is a good PR but it lacks in being generic. Scroll behavior is also supported by other browsers and should generally have better performance than custom. Wouldn't it be better to call it just 'scrollBehavior' in document.documentElement.style If not - fallback to old custom smooth scrolling. Edit: Using native smooth scroll when available will also probably fix: #3225 |
Rather than adding another option for Firefox which interacts with Vimium's existing smooth scrolling option, it would be nice if we could always use the browser's smooth scrolling behavior. I've opened #4306 for discussion. |
Problem: Fake timestamps are provided to Vimium when
privacy.resistFingerprinting
is settrue
in Firefox which results in choppy and unpredictable scrolling.Solution: Added option for alternative smooth scroll using native
scrollBy
toggling between optionssmooth
andinstant
Fixes #3641