Easily create avatar to show a visual representation of a user profile using an image element or SVG object based on multiple styles and sizes.
To get started with the Avatar component, simply wrap your image inside the .uk-avatar and .uk-avatar-image classes.
To create a circular avatar, simply apply the uk-avatar-rounded class to the wrapper.
To add a border around your avatar, include the uk-avatar-bordered class along with any other modifiers you like.
If there’s no image available, display initials using the .uk-avatar-text element. This is useful for fallback states or text-based avatars.
To indicate status or notifications, you can add a small dot using the uk-avatar-dot class. Or, choose one of the following classes to reposition the dot indicator:
| Class | Position |
|---|---|
uk-avatar-dot-top | Top center |
uk-avatar-dot-top-left | Top left |
uk-avatar-dot-top-right | Top right |
uk-avatar-dot-right | Right center |
uk-avatar-dot-bottom | Bottom center |
uk-avatar-dot-bottom-left | Bottom left |
uk-avatar-dot-bottom-right | Bottom right |
uk-avatar-dot-left | Left center |
Stack multiple avatars together to represent a group or team. Use flex utilities and negative spacing to achieve the overlapping effect.