Respect prefers-reduced-motion when adding motion.
This commit is contained in:
parent
5c62458176
commit
4bd1e30dba
1 changed files with 14 additions and 5 deletions
|
|
@ -38,6 +38,14 @@ a:active {
|
|||
text-decoration: none;
|
||||
}
|
||||
|
||||
// Use smooth scrolling unless user prefer less motion.
|
||||
@media (prefers-reduced-motion: no-preference) {
|
||||
:has(:target) {
|
||||
scroll-behavior: smooth;
|
||||
scroll-padding-block-start: var(--gutters);
|
||||
}
|
||||
}
|
||||
|
||||
.link-nav,
|
||||
%link-nav {
|
||||
a {
|
||||
|
|
|
|||
Loading…
Reference in a new issue