File tree Expand file tree Collapse file tree 4 files changed +22
-25
lines changed Expand file tree Collapse file tree 4 files changed +22
-25
lines changed Original file line number Diff line number Diff line change 99 width : 100% ;
1010}
1111
12- .demo-icons {
13- font-size : 100% ;
14- height : inherit ;
15- vertical-align : top ;
16- width : inherit ;
17- }
18-
1912.demo-card {
2013 margin : 16px ;
2114}
Original file line number Diff line number Diff line change 4040 < td >
4141 < md-input-container class ="demo-full-width ">
4242 < input mdInput #postalCode maxLength ="5 " placeholder ="Postal Code " value ="94043 ">
43- < md-hint align ="end "> {{postalCode.value.length}} / 5</ md-hint >
43+ < md-hint align ="end ">
44+ < md-icon > mode_edit</ md-icon >
45+ {{postalCode.value.length}} / 5
46+ </ md-hint >
4447 </ md-input-container >
4548 </ td >
4649 </ tr > </ table >
5154< md-card class ="demo-card demo-basic ">
5255 < md-toolbar color ="primary "> Prefix + Suffix</ md-toolbar >
5356 < md-card-content >
57+ < h4 > Text</ h4 >
5458 < md-input-container align ="end ">
5559 < input mdInput placeholder ="amount ">
5660 < span mdPrefix > $ </ span >
5761 < span mdSuffix > .00</ span >
5862 </ md-input-container >
63+
64+ < h4 > Icons</ h4 >
65+ < md-input-container >
66+ < input mdInput placeholder ="amount ">
67+ < md-icon mdPrefix > attach_money</ md-icon >
68+ < md-icon mdSuffix > mode_edit</ md-icon >
69+ </ md-input-container >
5970 </ md-card-content >
6071</ md-card >
6172
@@ -152,10 +163,10 @@ <h4>Textarea</h4>
152163 < md-input-container >
153164 < input mdInput >
154165 < md-placeholder >
155- I < md-icon class =" demo-icons " > favorite</ md-icon > < b > bold</ b > placeholder
166+ I < md-icon > favorite</ md-icon > < b > bold</ b > placeholder
156167 </ md-placeholder >
157168 < md-hint >
158- I also < md-icon class =" demo-icons " > home</ md-icon > < i > italic</ i > hint labels
169+ I also < md-icon > home</ md-icon > < i > italic</ i > hint labels
159170 </ md-hint >
160171 </ md-input-container >
161172 </ p >
Original file line number Diff line number Diff line change 88 width : 100% ;
99}
1010
11- .demo-icons {
12- font-size : 100% ;
13- height : inherit ;
14- vertical-align : top ;
15- width : inherit ;
16- }
17-
1811.demo-card {
1912 margin : 16px ;
2013}
Original file line number Diff line number Diff line change @@ -27,6 +27,14 @@ $mat-input-underline-disabled-background-image:
2727 [dir = ' rtl' ] & {
2828 text-align : right ;
2929 }
30+
31+ // Allow icons in a prefix/suffix/hint/etc to adapt to the correct size.
32+ & .mat-icon {
33+ width : auto ;
34+ height : auto ;
35+ font-size : 100% ;
36+ vertical-align : top ;
37+ }
3038}
3139
3240// Global wrapper. We need to apply margin to the element for spacing, but
@@ -238,12 +246,4 @@ $mat-input-underline-disabled-background-image:
238246 // Prevents the prefix and suffix from stretching together with the container.
239247 width : 0.1px ;
240248 white-space : nowrap ;
241-
242- // Allow icons in a prefix/suffix to adapt to the correct size.
243- & .mat-icon {
244- width : auto ;
245- height : auto ;
246- font-size : 100% ;
247- vertical-align : top ;
248- }
249249}
You can’t perform that action at this time.
0 commit comments