Skip to content

Data display

IAvatar

A person or an organisation, at a glance, with initials when there is no image.

ARBLCW

Initials

name is enough: the first letters of the first and last words are used, so "Ana María Ruiz Vega" gives AV. A single name gives one letter. Pass initials to override.

ARAVPAZ

With an image

The initials show while the image loads and stay if it fails. Set delay-ms to hold them back briefly, so a fast connection goes straight to the photo.

vue
<IAvatar src="/ana.jpg" name="Ana Ruiz" :delay-ms="400" />

alt defaults to empty, since an avatar usually sits beside the same person's name. Give it an alt when the image is the only mention of who this is.

Sizes and shapes

Circle for a person, square for a company or a project.

ARARARARAR

Status

A presence dot in the corner, ringed in the page background.

ARBLCWDO

The dot carries a name, defaulting to the status word. Pass status-label for something more specific.

Props

PropTypeDefaultDescription
srcstring
altstring''Leave empty beside a visible name
namestringDrives the initials
initialsstringOverrides the derived initials
size'xs' | 'sm' | 'md' | 'lg' | 'xl''md'
shape'circle' | 'square''circle'
status'online' | 'busy' | 'away' | 'offline'Presence dot
statusLabelstringthe status wordNames that dot
delayMsnumberHold the fallback back while the image loads
unstyledbooleanSkip built-in classes
ui{ root?, image?, fallback?, status? }Per-slot class overrides

Slots

SlotDescription
fallbackReplaces the initials — an icon, say

See IAvatarGroup for stacking several of them together.