Skip to content

Commit 68e2f46

Browse files
devversiontinayuangao
authored andcommitted
fix(input): underline should only be thicker if focused (#6152)
* Currently the underline of the input container is always `2px` thick if the input is invalid. As per specifications the underline should be `1dp/px` if not focused.
1 parent a185581 commit 68e2f46

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

src/lib/input/input-container.scss

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -202,7 +202,7 @@ textarea.mat-input-element {
202202

203203
.mat-input-ripple {
204204
position: absolute;
205-
height: $mat-input-underline-height * 2;
205+
height: $mat-input-underline-height;
206206
top: 0;
207207
left: 0;
208208
width: 100%;
@@ -211,6 +211,10 @@ textarea.mat-input-element {
211211
visibility: hidden;
212212
transition: background-color $swift-ease-in-duration $swift-ease-in-timing-function;
213213

214+
.mat-focused & {
215+
height: $mat-input-underline-height * 2;
216+
}
217+
214218
.mat-focused &,
215219
.mat-input-invalid & {
216220
visibility: visible;

0 commit comments

Comments
 (0)