Avatar
An image, fallback, status, and tooltip representation for a person or entity.
An image, fallback, status, and tooltip representation for a person or entity.
Backed by Base UI Avatar for upstream behavior and configuration. Zenos owns the public API, styling, and composition shown on this page.
Import
Section titled “Import”import { Avatar } from "@zentara-co/zenos-ui";Use a named size for the shared scale or one of the supported numeric pixel sizes for a specific context.
Shapes
Section titled “Shapes”Status
Section titled “Status”Status dots contribute their label to the Avatar’s accessible name. Do not rely on the dot color alone.
Fallbacks and tooltips
Section titled “Fallbacks and tooltips”name generates initials and is the default tooltip. A failed image falls back to initials, while an unnamed avatar uses the generic person icon.
Custom styling
Section titled “Custom styling”Use className on Avatar to style its root and stable slots such as avatar-fallback. Status content remains independently customizable through Avatar.StatusDot. Keep name, alt, and the status label meaningful when changing the visual treatment.
Avatar Avatar.Root Avatar.Image Avatar.Fallback Avatar.StatusDot
API
| Prop | Type | Default | Description |
|---|---|---|---|
src | string | — | Image URL. |
alt | string | — | Image alternative text. |
name | string | — | Display name used to generate initials and tooltip content. |
Root.size | AvatarSize | md | Named or supported numeric size. |
shape | circle | rounded | square | circle | Avatar geometry. |
tooltip | boolean | string | true | Uses the name or a custom string as tooltip content. |
Unless narrowed above, each DOM-rendering part also accepts its underlying native or Base UI props,
including className, style, aria-*, and data-*.
Accessibility
Section titled “Accessibility”Avatar uses Base UI’s image loading and fallback behavior. Provide name or alt for meaningful avatars, label status dots, and use tooltip={false} only when the surrounding interface already identifies the person.