|
2 | 2 | @import '../core/style/form-common'; |
3 | 3 |
|
4 | 4 |
|
5 | | -$md-input-floating-placeholder-scale-factor: 0.75 !default; |
| 5 | +$md-floating-placeholder-scale-factor: 0.75 !default; |
6 | 6 |
|
7 | 7 | // Gradient for showing the dashed line when the input is disabled. |
8 | 8 | $md-input-underline-disabled-background-image: |
9 | 9 | linear-gradient(to right, rgba(0, 0, 0, 0.26) 0%, rgba(0, 0, 0, 0.26) 33%, transparent 0%); |
10 | 10 |
|
11 | 11 | // Applies a floating placeholder above the input itself. |
12 | | -@mixin md-input-placeholder-floating { |
| 12 | +@mixin md-placeholder-floating { |
13 | 13 | display: block; |
14 | 14 | padding-bottom: 5px; |
15 | | - transform: translateY(-100%) scale($md-input-floating-placeholder-scale-factor); |
16 | | - width: 100% / $md-input-floating-placeholder-scale-factor; |
| 15 | + transform: translateY(-100%) scale($md-floating-placeholder-scale-factor); |
| 16 | + width: 100% / $md-floating-placeholder-scale-factor; |
17 | 17 | } |
18 | 18 |
|
19 | 19 | .md-input-wrapper { |
@@ -57,7 +57,7 @@ $md-input-underline-disabled-background-image: |
57 | 57 | } |
58 | 58 |
|
59 | 59 | // The Input element proper. |
60 | | -input[md-input], textarea[md-input] { |
| 60 | +input[md-input], textarea[md-textarea] { |
61 | 61 | // Font needs to be inherited, because by default <input> has a system font. |
62 | 62 | font: inherit; |
63 | 63 |
|
@@ -93,15 +93,15 @@ input[md-input], textarea[md-input] { |
93 | 93 | // Once the autofill is committed, a change event happen and the regular md-input |
94 | 94 | // classes take over to fulfill this behaviour. |
95 | 95 | // Assumes the autofill is non-empty. |
96 | | - &:-webkit-autofill + .md-input-placeholder.md-float { |
97 | | - @include md-input-placeholder-floating; |
| 96 | + &:-webkit-autofill + .md-placeholder.md-float { |
| 97 | + @include md-placeholder-floating; |
98 | 98 | } |
99 | 99 | } |
100 | 100 |
|
101 | 101 | // The placeholder label. This is invisible unless it is. The logic to show it is |
102 | 102 | // basically `empty || (float && (!empty || focused))`. Float is dependent on the |
103 | 103 | // `floatingPlaceholder` input. |
104 | | -.md-input-placeholder { |
| 104 | +.md-placeholder { |
105 | 105 | // The placeholder is after the <input>, but needs to be aligned top-left of the |
106 | 106 | // infix <div>. |
107 | 107 | position: absolute; |
@@ -133,7 +133,7 @@ input[md-input], textarea[md-input] { |
133 | 133 |
|
134 | 134 | // Show the placeholder above the input when it's not empty, or focused. |
135 | 135 | &.md-float:not(.md-empty), &.md-float.md-focused { |
136 | | - @include md-input-placeholder-floating; |
| 136 | + @include md-placeholder-floating; |
137 | 137 | } |
138 | 138 |
|
139 | 139 | [dir='rtl'] & { |
|
0 commit comments