View Source LiveViewUI.UI.Avatar (LiveViewUI v0.0.7)
A simple avatar component for displaying user profile images with optional fallbacks.
Example Usage
Here is a basic example of setting up an avatar with an image and a fallback:
<Avatar.root>
<Avatar.image src="/path/to/image.jpg" alt="User Avatar" />
<Avatar.fallback>
<span>U</span>
</Avatar.fallback>
</Avatar.root>This structure allows you to display a user's avatar image with a fallback in case the image is not available.
Summary
Functions
Attributes
class(:any) - Defaults tonil.- Global attributes are accepted.
Slots
inner_block(required)
Attributes
class(:any) - Defaults tonil.- Global attributes are accepted. Supports all globals plus:
["src", "alt"].
Attributes
id(:string) (required)class(:any) - Defaults tonil.- Global attributes are accepted.
Slots
inner_block(required)
Functions
Attributes
class(:any) - Defaults tonil.- Global attributes are accepted.
Slots
inner_block(required)
Attributes
class(:any) - Defaults tonil.- Global attributes are accepted. Supports all globals plus:
["src", "alt"].
Attributes
id(:string) (required)class(:any) - Defaults tonil.- Global attributes are accepted.
Slots
inner_block(required)