Skip to content
This repository was archived by the owner on Sep 5, 2024. It is now read-only.

Commit dfa0a0c

Browse files
David MezaThomasBurleson
authored andcommitted
fix(select): fix layout issue
- Make selector less agressive restricting it to the text span only - Add a max width, so the overflow rule will go in effect if we reach the width of the container - Allow span to shrink if width is greather than that of the input container Closes #6200 and #6312 Closes #7509
1 parent b8c2d51 commit dfa0a0c

File tree

1 file changed

+8
-6
lines changed

1 file changed

+8
-6
lines changed

src/components/select/select.scss

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -104,16 +104,18 @@ md-select {
104104
min-height: 26px;
105105
flex-grow: 1;
106106

107-
._md-text {
108-
display: inline;
109-
}
110107

111-
*:first-child {
112-
flex: 1 0 auto;
108+
> span:not(._md-select-icon) {
109+
max-width: 100%;
110+
flex: 1 1 auto;
111+
transform: translate3d(0, 2px, 0);
113112
text-overflow: ellipsis;
114113
white-space: nowrap;
115114
overflow: hidden;
116-
transform: translate3d(0, 2px, 0);
115+
116+
._md-text {
117+
display: inline;
118+
}
117119
}
118120

119121
._md-select-icon {

0 commit comments

Comments
 (0)