-
Notifications
You must be signed in to change notification settings - Fork 176
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
[Accounts] Use KDS Buttons #3891
[Accounts] Use KDS Buttons #3891
Conversation
d7e44a5
to
d76f6d3
Compare
contentcuration/contentcuration/frontend/accounts/pages/accountDeleted/AccountDeleted.vue
Show resolved
Hide resolved
d76f6d3
to
9920f1a
Compare
401dd6b
to
295bde7
Compare
</VBtn> | ||
<KButton | ||
primary | ||
class="w-100" |
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.
Definitely nothing blocking and can also be a matter of personal style - if that'd be helpful in future work, when there is a one-line style, it may be simpler to use and read :style="{ width: '100%' }"
rather than defining a new class which is quite commonly used syntax in LE's codebases.
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.
Thank you @AlexVelezLl, all is looking good to me and I also manually tested that I can use updated links and buttons as expected. Also thanks for the helpful description of the compatibility of the previous and new approach, it helped me to understand the decisions you made in the code.
Thanks for reviewing this @MisRob ! |
Summary
Description of the change(s) you made
Use KDS KButton or KRouterLink components instead of Vuetify's VBtn in accounts app.
Manual verification steps performed
Screenshots
A couple of remarkable changes are the replacement of raised buttons for link buttons in favor of consistency with other sections (We could keep the raised buttons if it makes more sense):
References
Addresses #3148
Comments
A difference between using VBtn with KButton, is that in VBtn you can specify a
large
button, which is not in KButton, so the buttons will look a bit smaller:Another difference is that
KButton
does not support any prop to make the element Block instead of inline-block, so if we want the button to fill the full width we need to add classes to set the width: 100%.Pitfalls of replacing
ActionLink
with KDS components:ActionLink
component is that by default it has the:title=“text”
attribute in the span element which is not in theKRouterLink
orKExternalLink
component (which for example enables a native browser popup in Chrome), although we could pass the span with that attribute as slot if necessary.KRouterLink
does not support theopenInNewTab
functionality, something we can have with theActionLink
component in conjunction with the:to
prop (InKExternalLink
it is supported but not inKRouterLink
).ActionLink
props that control thetruncate
andnotranslate
classes are not supported in eitherKRouterLink
orKExternalLink
, although they can be achieved by passing the span as slot.Contributor's Checklist
Studio-specifc:
notranslate
class been added to elements that shouldn't be translated by Google Chrome's automatic translation feature (e.g. icons, user-generated text)pages
,components
, andlayouts
directories as described in the docsTesting:
Reviewer's Checklist
This section is for reviewers to fill out.
yarn
andpip
)