-
Notifications
You must be signed in to change notification settings - Fork 264
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
feat(web-core): new VtsLink component #8000
base: master
Are you sure you want to change the base?
Conversation
eba6c5d
to
ce0408a
Compare
@@ -0,0 +1,137 @@ | |||
<template> |
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.
The component's version is missing:
<template> | |
<!-- v1 --> | |
<template> |
@@ -0,0 +1,137 @@ | |||
<template> | |||
<component :is="component" :class="classes" class="vts-link" v-bind="attributes"> | |||
<UiIcon :icon="icon" color="current" /> |
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.
Since the icon component has been updated to VtsIcon
, what do you think of rebasing this PR and using the new version of the icon component?
<UiIcon :icon="icon" color="current" /> | |
<VtsIcon :icon color="current" /> |
small: 'typo p3-regular', | ||
medium: 'typo p1-regular', |
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.
In the typography styles, there is a -underline
variant, what do you think of using it? This would avoid adding the text-decoration
CSS property and match the typography used in the design system:
small: 'typo p3-regular', | |
medium: 'typo p1-regular', | |
small: 'typo p3-regular-underline', | |
medium: 'typo p1-regular-underline', |
align-items: center; | ||
gap: 0.8rem; | ||
color: var(--vts-link--color); | ||
text-decoration: underline; |
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 needed if using the -underline
typography variants:
text-decoration: underline; |
<VtsLink v-bind="properties">This is a link</VtsLink> | ||
|
||
<div v-if="!properties.to && !properties.href" class="info"> | ||
<UiIcon :icon="faInfoCircle" color="normal" /> |
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.
Same as in VtsLink
component, after a rebase, the icon component could be updated to VtsIcon
and the color prop to 'brand'
:
<UiIcon :icon="faInfoCircle" color="normal" /> | |
<VtsIcon :icon="faInfoCircle" color="brand" /> |
Link is disabled because no `href` or `to` is provided | ||
</div> | ||
<div v-else-if="properties.to && properties.href" class="info"> | ||
<UiIcon :icon="faExclamationTriangle" color="warning" /> |
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.
Same here:
<UiIcon :icon="faExclamationTriangle" color="warning" /> | |
<VtsIcon :icon="faExclamationTriangle" color="warning" /> |
<component :is="component" :class="classes" class="vts-link" v-bind="attributes"> | ||
<UiIcon :icon="icon" color="current" /> | ||
<slot /> | ||
<UiIcon |
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.
Same here:
<UiIcon | |
<VtsIcon |
Description
New
VtsLink
component (Design System)Checklist
Fixes #007
,See xoa-support#42
,See https://...
)Introduced by
CHANGELOG.unreleased.md