Components
Loading preview...
An easily stylable avatar component built with Base UI components.
npx shadcn@latest add https://21st.dev/r/sean0205/base-avatar-1import { Avatar, AvatarFallback, AvatarImage } from '@/components/ui/base-avatar';
import { Button } from '@/components/ui/base-button';
export default function AvatarDemo() {
return (
<div className="flex -space-x-2">
<Avatar>
<AvatarImage src="https://avatars.githubusercontent.com/u/124599?v=4" alt="@reui" className="border-2 border-background hover:z-10" />
<AvatarFallback>CH</AvatarFallback>
</Avatar>
<Avatar>
<AvatarImage src="https://avatars.githubusercontent.com/u/124599?v=4" alt="@reui" className="border-2 border-background hover:z-10" />
<AvatarFallback>CH</AvatarFallback>
</Avatar>
<Avatar>
<AvatarImage src="https://avatars.githubusercontent.com/u/124599?v=4" alt="@reui" className="border-2 border-background hover:z-10" />
<AvatarFallback>CH</AvatarFallback>
</Avatar>
<Avatar>
<AvatarImage src="https://avatars.githubusercontent.com/u/124599?v=4" alt="@reui" className="border-2 border-background hover:z-10" />
<AvatarFallback>CH</AvatarFallback>
</Avatar>
<Button
variant="secondary"
mode="icon"
shape="circle"
className="relative size-10 border-2 border-background hover:z-10"
>
+7
</Button>
</div>
);
}