Skip to content

fix(button): don't use divs in button template #20376

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Aug 28, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/material-experimental/mdc-button/button.html
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
The indicator can't be directly on the button, because MDC uses ::before for high contrast
indication and it can't be on the ripple, because it has a border radius and overflow: hidden.
-->
<div class="mat-mdc-focus-indicator"></div>
<span class="mat-mdc-focus-indicator"></span>

<ng-content select=".material-icons[iconPositionEnd], mat-icon[iconPositionEnd]">
</ng-content>
Expand Down
12 changes: 6 additions & 6 deletions src/material/button/button.html
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<span class="mat-button-wrapper"><ng-content></ng-content></span>
<div matRipple class="mat-button-ripple"
[class.mat-button-ripple-round]="isRoundButton || isIconButton"
[matRippleDisabled]="_isRippleDisabled()"
[matRippleCentered]="isIconButton"
[matRippleTrigger]="_getHostElement()"></div>
<div class="mat-button-focus-overlay"></div>
<span matRipple class="mat-button-ripple"
[class.mat-button-ripple-round]="isRoundButton || isIconButton"
[matRippleDisabled]="_isRippleDisabled()"
[matRippleCentered]="isIconButton"
[matRippleTrigger]="_getHostElement()"></span>
<span class="mat-button-focus-overlay"></span>