-
Notifications
You must be signed in to change notification settings - Fork 6.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix(input-container): prefix and suffix stretching together with parent #2496
Conversation
|
||
// Prevents the prefix and suffix from stretching together with the container. | ||
.md-input-prefix, .md-input-suffix { | ||
width: 0.1px; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why is this width needed?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It kind of acts as a max-width
, otherwise the table cells stretch out.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I see, is there a reason we have to use table as opposed to flex? I had started a PR to convert it to flex at some point, but I don't know what happened to it...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not sure, IIRC @hansl implemented it like this initially, but I don't know what the reasoning was.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ok, Jeremy's comment on #2581 explains why we're avoiding flex here.
Prevents the input's suffix and prefix from stretching together with their parent node and leaving some weird spacing between themselves and the input. This was a side-effect of using `display: table-cell`. Fixes angular#2493. Fixes angular#1881. Fixes angular#1421.
3f1aa20
to
c9de8fd
Compare
This issue has been automatically locked due to inactivity. Read more about our automatic conversation locking policy. This action has been performed automatically by a bot. |
Prevents the input's suffix and prefix from stretching together with their parent node and leaving some weird spacing between themselves and the input. This was a side-effect of using
display: table-cell
.Fixes #2493.
Fixes #1881.
Fixes #1421.