Components · Avatar
Displays a user's profile picture with initials fallback.
| Prop | Type | Default | Required | Description |
|---|---|---|---|---|
| src | string | — | — | URL of the profile image. |
| name | string | — | — | Full name used to generate initials when no image is provided. |
| size | 'xs' | 'sm' | 'md' | 'lg' | 'xl' | 'md' | — | Controls avatar dimensions. |
| badge | boolean | — | — | Shows a status badge on the avatar. |
| badgeColor | string | — | — | Colour of the status badge. |
| fallback | ReactNode | — | — | Custom fallback rendered when the image fails to load and no name is provided. |
import { Avatar } from '@nexub/react';