WebKit now supports the
prefers-reduced-motion
media feature, part of CSS Media Queries Level 5, User Preferences. The feature can be used in a CSS@media
block or through thewindow.matchMedia()
interface in JavaScript. Web designers and developers can use this feature to serve alternate animations that avoid motion sickness triggers experienced by some site visitors.To explain who this media feature is for, and how it’s intended to work, we’ll cover some background. Skip directly to the code samples or
prefers-reduced-motion
demo if you wish.