ui-kit0.0

Display

Avatar

People and accounts, alone or in groups.

Sizes and shapes

Five sizes from 24 to 64px, as a circle for people or a rounded square for organisations and products. Initials scale with the size.

Amina RahmanARAmina RahmanARAmina RahmanARAmina RahmanARAmina RahmanAR
NVNVNVNVNV

When to use

  • Identify a person or account: comments, assignees, menus, tables.
  • Show who is in a group, with a “+N” for the rest.
  • Show presence with a status dot.

Not for: decorative images (use an image), or logos that need their own aspect ratio.

Image and fallback

The fallback is always rendered under the image. If the image fails to load, AvatarImage removes itself and the initials show. Use getInitials(name) for up to two letters, or put an icon inside.

Tomás HerreraTH
Image fails
PN
No image
Icon

Status

A presence dot with a ring in the surface colour. Its colour is status only, and it has an accessible name.

  • AR
    Amina Rahman
    online
  • JW
    Jonas Weber
    away
  • MT
    Mei Tanaka
    busy
  • CD
    Carlos Díaz
    offline

Group

AvatarGroup overlaps its avatars with a ring. max collapses the rest into “+N”. On a card, set --ui-avatar-ring to the card surface so the ring blends in.

ARJWMTCD+3
Atlas redesign
ARJWMT+4

API

Avatar

PropTypeDefaultDescription
size'xs' | 'sm' | 'md' | 'lg' | 'xl''md'24 / 32 / 40 / 48 / 64px. Inherited from an AvatarGroup when not set.
shape'circle' | 'rounded''circle'Rounded square for organisations.
status'online' | 'away' | 'busy' | 'offline'—Presence dot on the bottom-right.
statusLabelstring—Accessible name for the dot. Defaults to “Online”…

AvatarImage

PropTypeDefaultDescription
srcstring—Image URL. Nothing is rendered if it is missing or fails.
altstring—Required. The person’s name; "" only if the name is shown beside it.

AvatarGroup

PropTypeDefaultDescription
size'xs' | 'sm' | 'md' | 'lg' | 'xl'—Size for every avatar inside.
maxnumber—Show this many, then a “+N” avatar.

AvatarFallback takes initials or an icon. All parts forward ref, className and native props.

Accessibility

  • The image’s alt text is the person’s name. When the name is printed next to the avatar, pass alt="" so it is not read twice.
  • The status dot is role="img" with a label (“Online”), never colour alone.
  • AvatarGroup is role="group"; give it an aria-label (“Project members”).
  • Fallback initials are real text and meet 4.5:1 on their fill in light and dark.

Motion

  • No motion of its own: avatars are static so a list of them stays calm.
  • Only AvatarImage is a client component (it watches for load errors); Avatar, AvatarFallback and AvatarGroup render on the server.