@@ -122,10 +122,12 @@ textarea.mat-input-element {
122
122
margin : -2px 0 ;
123
123
}
124
124
125
- // Encoded material design select arrow svg
126
- /* stylelint-disable max-line-length */
127
- $mat-native-select-arrow-svg : ' data:image/svg+xml;charset=utf8,%3Csvg%20width%3D%2210%22%20height%3D%225%22%20viewBox%3D%227%2010%2010%205%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%3E%3Cpath%20fill%3D%22%230%22%20fill-rule%3D%22evenodd%22%20opacity%3D%22.54%22%20d%3D%22M7%2010l5%205%205-5z%22%2F%3E%3C%2Fsvg%3E' ;
128
- /* stylelint-enable */
125
+ // URL-encoded Material Design select arrow SVG.
126
+ $mat-native-select-arrow-svg : ' ' +
127
+ ' data:image/svg+xml;charset=utf8,%3Csvg%20width%3D%2210%22%20height%3D%225%22%20' +
128
+ ' viewBox%3D%227%2010%2010%205%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fs' +
129
+ ' vg%22%3E%3Cpath%20fill%3D%22%230%22%20fill-rule%3D%22evenodd%22%20opacity%3D%22' +
130
+ ' .54%22%20d%3D%22M7%2010l5%205%205-5z%22%2F%3E%3C%2Fsvg%3E' ;
129
131
130
132
// Remove the native select down arrow and replace it with material design arrow
131
133
select .mat-input-element {
@@ -136,12 +138,17 @@ select.mat-input-element {
136
138
-webkit-appearance : none ;
137
139
position : relative ;
138
140
background-color : transparent ;
139
- background-image : url ($mat-native-select-arrow-svg );
140
141
background-repeat : no-repeat ;
141
142
display : inline-flex ;
142
143
box-sizing : border-box ;
143
144
background-position : right center ;
144
145
146
+ // Native multi-selects are rendered inline which
147
+ // means that they shouldn't have a dropdown arrow.
148
+ & :not ([multiple ]) {
149
+ background-image : url ($mat-native-select-arrow-svg );
150
+ }
151
+
145
152
[dir = ' rtl' ] & {
146
153
background-position : left center ;
147
154
}
0 commit comments