Noora.Avatar (noora v0.1.0-alpha.3)
A component for rendering an avatar image or initials if an image is not available.
Summary
Functions
Attributes
id
(:string
) (required) - The unique identifier for the avatar.name
(:string
) (required) - The name of the account to render the avatar for.color
(:string
) - The color of the avatar. Defaults to"pink"
. Must be one of"gray"
,"red"
,"orange"
,"yellow"
,"azure"
,"blue"
,"purple"
, or"pink"
.image_href
(:string
) - The URL of the image to render as the avatar. Defaults tonil
.fallback
(:string
) - Determines the fallback for when an image is not available. Can be either initials or a placeholder image. Defaults to"initials"
. Must be one of"initials"
, or"placeholder"
.on_status_change
(:string
) - Event handler for when the status of the avatar changes. Defaults tonil
.size
(:string
) - The size of the avatar. Defaults to medium. Defaults to"medium"
. Must be one of"3xsmall"
,"2xsmall"
,"small"
,"medium"
,"large"
,"2xlarge"
, or"3xlarge"
.- Global attributes are accepted.