Make use of the `prefers-reduced-motion` media query
See original GitHub issueAre there any plans to add support for the prefers-reduced-motion
media query? Here is the CSS Tricks article about it.
Pretty much, if a user has set in their browser/system preferences they’d like reduce the amount of motion they see, we can know about.
What I’d purpose (if everyone thinks this is a good idea), is adjusting scss/mixins/_transition.scss to look more like:
@mixin transition($transition...) {
@if $enable-transitions {
@if length($transition) == 0 {
transition: $transition-base;
} @else {
transition: $transition;
}
@media screen and (prefers-reduced-motion: reduce) {
transition: none;
}
}
}
Issue Analytics
- State:
- Created 6 years ago
- Reactions:2
- Comments:9 (7 by maintainers)
Top Results From Across the Web
prefers-reduced-motion - CSS: Cascading Style Sheets | MDN
The prefers-reduced-motion CSS media feature is used to detect if the user has requested that the system minimize the amount of ...
Read more >prefers-reduced-motion: Sometimes less movement is more
The prefers-reduced-motion media query detects whether the user has requested that the system minimize the amount of animation or motion it ...
Read more >An Introduction to the Reduced Motion Media Query
Safari 10.1 introduced the Reduced Motion Media Query. It is a non-vendor-prefixed declaration that allows developers to “create styles that ...
Read more >Respecting Users' Motion Preferences - Smashing Magazine
Most new operating systems enable the user to set their motion preferences in their system-level settings. The prefers-reduced-motion media ...
Read more >C39: Using the CSS reduce-motion query to prevent motion
The objective of this technique is to allow users to prevent animation from being displayed on Web pages, via the use of 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
@MikeRogers0 definite thumbs up from me - although its a AAA level issue in WCAG2.1 and currently only 100% supported on ios and safari that doesnt mean we shouldnt strive to make everything as accessible as possible.
I came up with a similar css change for Joomla https://github.com/joomla/joomla-cms/issues/19694 which is based on a non bootstrap one for Drupal https://www.drupal.org/project/drupal/issues/2940012
As I am not even remotely a css wizard I am sure whatever you propose will be much better and will get a big thumbs up from me.
Depends if @mdo and rest of the team feel it’s a worthwhile addition, but yes a PR is always nice 😃