File tree 2 files changed +23
-0
lines changed
2 files changed +23
-0
lines changed Original file line number Diff line number Diff line change @@ -193,6 +193,22 @@ select.mat-input-element {
193
193
}
194
194
}
195
195
196
+ .mat-input-element {
197
+ // The arrow is 2 * $arrow-size wide and we add one more width for some spacing.
198
+ $padding : $arrow-size * 3 ;
199
+ padding-right : $padding ;
200
+
201
+ [dir = ' rtl' ] & {
202
+ padding-right : 0 ;
203
+ padding-left : $padding ;
204
+ }
205
+ }
206
+
207
+ // Ensure that long labels don't collide with the select arrow.
208
+ .mat-form-field-label-wrapper {
209
+ max-width : calc (100% - #{$arrow-size * 2 } );
210
+ }
211
+
196
212
& .mat-form-field-appearance-outline .mat-form-field-infix ::after {
197
213
margin-top : - $arrow-size ;
198
214
}
Original file line number Diff line number Diff line change @@ -73,6 +73,13 @@ $mat-form-field-default-infix-width: 180px !default;
73
73
height : 100% ;
74
74
overflow : hidden ;
75
75
pointer-events : none ; // We shouldn't catch mouse events (let them through).
76
+
77
+ [dir = ' rtl' ] & {
78
+ // Usually this isn't necessary since the element is 100% wide, but
79
+ // when we've got a `select` node, we need to set a `max-width` on it.
80
+ left : auto ;
81
+ right : 0 ;
82
+ }
76
83
}
77
84
78
85
// The label itself. This is invisible unless it is. The logic to show it is
You can’t perform that action at this time.
0 commit comments