Allow to smooth scroll any element, not only OverlayScrollbars instance
See original GitHub issueHi!
We already have the instance.scroll()
method, but what if we want to scroll smoothly any scrollable HTML element, not necessarily customized with OverlayScrollbars?
Sure, we have native element.scrollTo({top: 100, behavior: 'smooth'})
, but it doesn’t allow us to controll scroll duration (it differs depending on scroll distance).
There are also other packages which allow us to do this. But since we use OverlayScrollbars and it already can do this, it would be great to have this function out-of-the-box.
Issue Analytics
- State:
- Created a year ago
- Comments:6 (1 by maintainers)
Top Results From Across the Web
Allow to smooth scroll any element, not only OverlayScrollbars ...
Hi! We already have the instance.scroll() method, but what if we want to scroll smoothly any scrollable HTML element, not necessarily customized with ......
Read more >Issues · KingSora/OverlayScrollbars - GitHub
A javascript scrollbar plugin that hides native scrollbars, provides custom styleable overlay scrollbars and keeps the native functionality and feeling.
Read more >Downsides of Smooth Scrolling - CSS-Tricks
Perhaps the largest downside of smooth scrolling is the potential to mismanage focus. Scrolling to an element in JavaScript is fine, so long...
Read more >ngx-scrollbar - npm
The [smoothScroll] directive allows you to scroll the host element smoothly using the scroll functions that works on cross-browser. Since v3.0.0 ...
Read more >Mac's overlay scrollbars can't be styled without reverting to ...
Here's an example: http://jsfiddle.net/leo/ht82ozhw/embedded/result/ Even if your OS' setting is to only show them while scrolling, they will be shown the ...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Hi, @andron13! Yes, with the help of additional
scroll-smooth
package. But it would be niceOverlayScrollbars
had this.@plashenkov @andron13 I’ll add the
scroll
function as an instance function and also as an static function in version2. I plan on releasing it end of september