Skip to content
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

[Accessibility improvement] Suppress animations with media-query #2629

Open
marcus-herrmann opened this issue Dec 6, 2019 · 0 comments
Open

Comments

@marcus-herrmann
Copy link
Contributor

[This is a ticket for the "accessibility backlog"]

For some users suffering from a motion sensitivity sudden movements caused by animations could cause, dizziness, vertigo or nausea such as vestibular disorders:

Imagine a world where your internal gyroscope is not working properly. Very similar to being intoxicated, things seem to move of their own accord, your feet never quite seem to be stable underneath you, and your senses are moving faster or slower than the rest of syour body.

Source: A11y Project's A primer to vestibular disorders

There is a way to detect a user preference about animations set in the user's Operating System. It could be detected with

@media (prefers-reduced-motion: reduce) {
    /* Disable animation on your selectors here */
}

Since browser support for this "user query" is good but not perfect I recommend to offer a setting to disable animations application-wide using state and persisting this setting in e.g. the database or localStorage.

More about on in the "Responsible Animation" pattern of accessible-app.com

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant