Skip to content

Commit

Permalink
Ally: Make the media queries consistent for reduce motion preference
Browse files Browse the repository at this point in the history
  • Loading branch information
himanshupathak95 committed Dec 26, 2024
1 parent 2fb1086 commit adcefa6
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions packages/block-library/src/image/style.scss
Original file line number Diff line number Diff line change
Expand Up @@ -167,7 +167,7 @@
text-align: center;
padding: 0;
border-radius: 4px;
@media not ( prefers-reduced-motion ) {
@media (prefers-reduced-motion: no-preference) {
transition: opacity 0.2s ease;
}

Expand Down Expand Up @@ -282,22 +282,22 @@
// or faster than the scrim to give a sense of depth.
&.active {
visibility: visible;
@media not ( prefers-reduced-motion ) {
@media (prefers-reduced-motion: no-preference) {
animation: both turn-on-visibility 0.25s;
}
img {
@media not ( prefers-reduced-motion ) {
@media (prefers-reduced-motion: no-preference) {
animation: both turn-on-visibility 0.35s;
}
}
}
&.show-closing-animation {
&:not(.active) {
@media not ( prefers-reduced-motion ) {
@media (prefers-reduced-motion: no-preference) {
animation: both turn-off-visibility 0.35s;
}
img {
@media not ( prefers-reduced-motion ) {
@media (prefers-reduced-motion: no-preference) {
animation: both turn-off-visibility 0.25s;
}
}
Expand Down

0 comments on commit adcefa6

Please sign in to comment.