-
Notifications
You must be signed in to change notification settings - Fork 112
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)!: button attributes refactored #191
Conversation
Good job! |
Good work! However, I believe using |
After discuss with @DamlaDemir, we think that |
can we fix the buttons on the tab component to secondary text button - icon only variant like before? |
Kudos, SonarCloud Quality Gate passed! |
@buseselvi we fixed it, can you check it again? |
@leventozen buttons look ok 👌 but this time in the hover state tooltip seems to slide down |
@buseselvi, this changes are not related to this bug, so we created another issue. thank you for your attention 🤖 |
🎉 This PR is included in version 2.0.0-beta.21 🎉 The release is available on: Your semantic-release bot 📦🚀 |
🎉 This PR is included in version 2.0.0 🎉 The release is available on: Your semantic-release bot 📦🚀 |
This is a BREAKING CHANGE
Currently we use boolean attributes for button variants (
primary
,secondary
,success
,danger
) and types (contained
,outline
,text
). In the beginning we thought this is easier to write but currently I see that this is conflicting with the approach how we use boolean attributes in other components and how we really should use them. Boolean attributes should not rely on other attributes. But now we are technically allowed to write<bl-button primary secondary>
and in this case result relies on our CSS specifity. And this type of writing does give the feeling that it's possible.I think we need to fix this as soon as possible to not make confusion for new comers.
This PR converts boolean variants to a more standart
variant
attribute with a defaultprimary
value again. I pickedfill
attribute value for button types (we use type in storybook) because probablytype
attribute will be needed in near future for using a button as a submitter of a form. Since HTMLbutton
hastype
I thought we should not usetype
for setting button asoutline
ortext
. Opinions are very welcome.