Skip to content

Avatar

The Avatar component provides a way to represent an image with a fallback for when the image cannot be loaded. It supports displaying initials derived from the name prop or an Avatar Icon if no name or src is provided.

Playground

Installation

import { Avatar } from '@harnessio/ui'
// ...
return (
<Avatar name="John Doe" src="/avatar.png" />
)

With Tooltip

Use AvatarWithTooltip to display a tooltip on hover.