Installation
npx shadcn@latest add @iconiq/avatarProps
Avatar
3 props
Compact motion avatar with a canonical Avatar export, optional image source, and fallback text for empty states.
src
stringImage URL rendered into a framework-agnostic img element. When present, the image fills the 42x42 circular mask with a blur-and-clip reveal animation.
fallback
stringDefault
?Text rendered in the center when no src is provided, typically initials or a short placeholder character.
className
stringMerged onto the root motion.div. The base component already fixes the size to 42x42 and applies the circular overflow mask.
Notes
The component does not forward refs or arbitrary DOM props; the public surface is only src, fallback, and className.
The root is a motion.div with pointer-style hover and tap animation, but it is not a button or link by itself.