【发布时间】:2019-03-07 14:26:43
【问题描述】:
我正在尝试自定义 MatButtonToggle,但难以将标签居中:
模板:
<mat-button-toggle-group name="condition" aria-label="Condition">
<mat-button-toggle value="and" checked>
<div>ET</div>
</mat-button-toggle>
<mat-button-toggle value="or">OU</mat-button-toggle>
</mat-button-toggle-group>
风格:
.mat-button-toggle-checked {
background-color: $secondary-color;
color: white;
}
mat-button-toggle-group {
height: 25px;
border-radius: 4px;
border: solid 1px $secondary-color;
}
mat-button-toggle {
font-size: 15px;
background-color: white;
color: $secondary-color;
}
我该怎么做?
【问题讨论】:
标签: css angular typescript sass angular-material