Skip to content

Commit

Permalink
fix(input): input placeholder not being hidden in IE under certain co…
Browse files Browse the repository at this point in the history
…nditions

Fixes cases where the input's native placeholder won't be hidden on IE, if the consumer was using a higher specificity selector to override the input color.

Fixes angular#4464.
  • Loading branch information
crisbeto committed May 11, 2017
1 parent f15619c commit a0772c7
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/lib/input/input-container.scss
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,9 @@ $mat-input-underline-disabled-background-image:
// display: none, because IE ends up preventing the user from
// focusing the input altogether.
@include input-placeholder {
color: transparent;
// Needs to be !important, because the placeholder will end up inheriting the
// input color in IE, if the consumer overrides it with a higher specificity.
color: transparent !important;
}
}

Expand Down

0 comments on commit a0772c7

Please sign in to comment.