Skip to content

KAvatar ​

示例 ​

Sizes & Shapes

SMLSQ

With image fallback

AB

Avatar component that displays an image with a text fallback.

Props ​

NameTypeDefaultDescription
srcstring—URL of the avatar image. Falls back to text if empty.
altstring—Alt text for the avatar image.
fallbackstring—Text to display when no image is provided.
size'sm' | 'default' | 'lg''default'Size of the avatar.
shape'circle' | 'square''circle'Shape of the avatar.

Basic Usage ​

User