Skip to content

Commit c26264f

Browse files
crisbetoamysorto
authored andcommitted
fix(material/radio): hidden circle visible on some zoom levels (#23154)
We transition the circle of a radio button to `scale(0.001)` in order to hide it and to work around an animation in IE. It seems that on higher system zoom levels (e.g. 125%+) the browser approximates the size to 1x1 which can be visible. These changes work around the issue by also setting `opacity: 0` while the circle is inactive and isn't animating. Fixes #22036. (cherry picked from commit 21bb4d5)
1 parent 48739eb commit c26264f

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

src/material/radio/radio.scss

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -90,10 +90,6 @@ $ripple-radius: 20px;
9090
// force browser to show background-color when using the print function
9191
@include vendor-prefixes.private-color-adjust(exact);
9292

93-
._mat-animation-noopable & {
94-
transition: none;
95-
}
96-
9793
.mat-radio-checked & {
9894
transform: scale(0.5);
9995
opacity: 1;
@@ -105,6 +101,10 @@ $ripple-radius: 20px;
105101
border: solid private.private-div($size, 2);
106102
}
107103
}
104+
105+
._mat-animation-noopable & {
106+
transition: none;
107+
}
108108
}
109109

110110
// Text label next to radio.

0 commit comments

Comments
 (0)