-
Notifications
You must be signed in to change notification settings - Fork 342
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
Stories rework: VaAvatar #3795
Stories rework: VaAvatar #3795
Conversation
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.
There are very small things. After fix - please merge on your own :).
components: { VaAvatar }, | ||
template: '<VaAvatar/>', | ||
template: ` | ||
<VaAvatar> |
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.
Let's use avatar with image as default example.
export const Color = () => ({ | ||
components: { VaAvatar }, | ||
template: ` | ||
[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.
Doesn't seem to be relevant. Same in other places.
[warning] |
export const Size = () => ({ | ||
components: { VaAvatar }, | ||
template: ` | ||
[smal] |
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.
Here small/medium etc is fine, as we have several options.
export const FontSize = () => ({ | ||
components: { VaAvatar }, | ||
template: ` | ||
[0.75rem] |
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.
[0.75rem] |
<VaAvatar | ||
src="https://randomuser.me/api/portraits/women/5.jpg" | ||
alt="image" | ||
> |
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.
> | |
/> |
|
||
export const FallbackText = () => ({ | ||
components: { VaAvatar }, | ||
template: '<VaAvatar src="https://not-exist" fallbackText="Fallback"/>', |
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.
export const FallbackRender = () => ({ | ||
components: { VaAvatar }, | ||
methods: { | ||
FallbackRender: () => h('b', { |
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.
FallbackRender: () => h('b', { | |
fallbackRender: () => h('b', { |
Methods start from lowercase.
}, | ||
}, 'Text'), | ||
}, | ||
template: '<VaAvatar src="https://not-exist" :fallbackRender="FallbackRender"/>', |
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.
template: '<VaAvatar src="https://not-exist" :fallbackRender="FallbackRender"/>', | |
template: '<VaAvatar src="https://not-exist" :fallbackRender="fallbackRender"/>', |
* va-avatar stories * va-avatar stories * va-avatar stories
Avatar stories