-
Notifications
You must be signed in to change notification settings - Fork 99
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(Button): do not shrink button when there is only one icon #1577
Conversation
Preview is ready. |
Playwright Test Component is ready. |
@teleginzhenya Could you add test for this case? |
3dec613
to
bd38edc
Compare
src/components/Button/Button.scss
Outdated
@@ -34,6 +34,7 @@ $block: '.#{variables.$ns}button'; | |||
color 0.15s linear; | |||
transform: scale(1); | |||
display: inline-flex; | |||
flex-shrink: 0; |
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.
That's not the cause of the problem. The problem is in the negative margins of .g-button__icon
element. Setting flex-shrink
to 0 would break user layouts relying on flex
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.
9047cd0
to
52889cb
Compare
Resetting plugin makes button with only icon shrink (#1529). Started to happen after flex refactoring (#1452)
Related issue #1529