Feature request: smooth scroll behaviour
Created by: MartijnCuppens
Setting scroll-behaviour
to smooth
will enable smooth scrolling when scrolling happens due to navigation or CSSOM scrolling APIs. In my opinion it is clearer if a user scrolls to the section where he needs to be instead of the instant scoll.
The scroll behaviour can be set on :root
or on every element (not inherited by default). Maybe make a variable, so this behaviour can easily be turned off if needed?
Currently only Chrome and Firefox support this feature, but it's more like an enhancement so I don't think this is an issue.
Demo: https://codepen.io/MartijnCuppens/pen/bYjEby?editors=1100 More info: https://developer.mozilla.org/en-US/docs/Web/CSS/scroll-behavior Support: https://caniuse.com/#feat=css-scroll-behavior