Skip to content

Commit 9853fb6

Browse files
committed
fix(button): ripples not being clipped to border radius on safari
Fixes the button ripples not being clipped to the border radius in Safari due to the individual ripples being on a different layer because they have an animation.
1 parent 5c8e0cb commit 9853fb6

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

src/lib/button/button.scss

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -89,6 +89,12 @@
8989
border-radius: inherit;
9090
}
9191

92+
// Fixes the ripples not clipping to the border radius on Safari. Uses `:not(:empty)`
93+
// in order to avoid creating extra layers when there aren't any ripples.
94+
.mat-button-ripple.mat-ripple:not(:empty) {
95+
transform: translateZ(0);
96+
}
97+
9298
// Element that overlays the button to show focus and hover effects.
9399
.mat-button-focus-overlay {
94100
border-radius: inherit;

0 commit comments

Comments
 (0)