-
Notifications
You must be signed in to change notification settings - Fork 6.8k
Closed
Labels
area: material/buttonfeatureThis issue represents a new feature or feature request rather than a bug or bug fixThis issue represents a new feature or feature request rather than a bug or bug fix
Description
Feature Description
It would be nice to add some styles to a mat-icon
within a mat-button
so that it more closely matches the design specs found in Material Design. This could potentially take the form of a new attribute, mat-inline
, placed on a mat-button
.
This is an image of what I'm imagining a regular mat-button
compared against a mat-inline mat-button
would look like:
Sample Usage
<button mat-flat-button mat-inline color="accent">
<mat-icon>account_circle</mat-icon>
W/ Inline
</button>
Potential Implementation
.mat-button-base[mat-inline] {
.mat-button-wrapper {
display: flex;
align-items: center;
}
.mat-icon {
height: 18px;
width: 18px;
font-size: 18px;
margin: 0 8px 0 -4px;
}
}
[dir='rtl'] .mat-button-base[mat-inline] .mat-icon {
margin: 0 -4px 0 8px;
}
Use Case
Whenever a user is creating an icon button, a user wouldn't have to refer to the material documentation & have to add these styles manually within their projects.
It helps to ensure alignment with Material's specs.
joebochill and huayunh
Metadata
Metadata
Assignees
Labels
area: material/buttonfeatureThis issue represents a new feature or feature request rather than a bug or bug fixThis issue represents a new feature or feature request rather than a bug or bug fix