Make WordPress Core

Changeset 50028


Ignore:
Timestamp:
01/27/2021 11:39:50 AM (6 years ago)
Author:
SergeyBiryukov
Message:

Accessibility: Administration: Respect the prefers-reduced-motion media query for update icon spinner animations.

The update icon rotation should not occur when the user has opted to reduce motion, for example by selecting the "Reduce motion" option in macOS' preferences or unselecting "Show animations in Windows" in Windows' preferences.

Follow-up to [47813], [50027].

Props xkon, audrasjb, johnbillion.
Fixes #52263. See #51476.

Location:
trunk/src
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-admin/css/common.css

    r50025 r50028  
    15401540}
    15411541
     1542@media (prefers-reduced-motion: reduce) {
     1543        .updating-message p:before,
     1544        .import-php .updating-message:before,
     1545        .button.updating-message:before,
     1546        .button.installing:before,
     1547        .plugins .column-auto-updates .dashicons-update.spin,
     1548        .theme-overlay .theme-autoupdate .dashicons-update.spin {
     1549                animation: none;
     1550        }
     1551}
     1552
    15421553.theme-overlay .theme-autoupdate .dashicons-update.spin {
    15431554        margin-right: 3px;
  • trunk/src/wp-includes/css/admin-bar.css

    r50027 r50028  
    592592        display: inline-block;
    593593        animation: rotation 2s infinite linear;
     594}
     595
     596@media (prefers-reduced-motion: reduce) {
     597        #wpadminbar #wp-admin-bar-updates.spin .ab-icon:before {
     598                animation: none;
     599        }
    594600}
    595601
Note: See TracChangeset for help on using the changeset viewer.