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
Give the .fakeScroll__track div a class when there is nothing to scroll #17
Comments
Good idea, thanks! |
Do you know when this might be added? Is there anything I can do to help? |
Hi I am spending all day to port my code to React and once it's done I'll release it along with the change you've requested (hopefully today but I'm currently facing one last tough bug with the React port) |
Done. update to |
Thanks! In order to get this working properly on my project, I had to remove the following from this.DOM.scope.classList.toggle('fakeScroll--hasBar', this.state.scrollRatio < 1) I then added the following to if (scrollHeight <= ownHeight) {
this.DOM.scope.classList.remove('fakeScroll--hasBar');
}
else {
this.DOM.scope.classList.add('fakeScroll--hasBar');
} |
Why did you remove it? You should not change the source code or you'll be out-of-sync with future updates... |
You can look at #18 for context. I couldn't get that to work correctly without the change I mentioned in my previous comment. |
When no scrolling is necessary, the
.fakeScroll__bar
div is hidden withdisplay: none
. This is good, but I think it would also be good if the.fakeScroll__track
div was given a class like.fakeScroll__has_hidden_bar
or something along those lines so that developers could more easily update the styling of the track when there is nothing to scroll.The text was updated successfully, but these errors were encountered: