Home / Function/ AvatarBadge() — ui Function Reference

AvatarBadge() — ui Function Reference

Architecture documentation for the AvatarBadge() function in avatar.tsx from the ui codebase.

Entity Profile

Dependency Diagram

graph TD
  ae60a6a6_0fc6_e295_3cff_50b6ad3a221d["AvatarBadge()"]
  be692f8d_42ed_9898_a305_5ee346d784a3["avatar.tsx"]
  ae60a6a6_0fc6_e295_3cff_50b6ad3a221d -->|defined in| be692f8d_42ed_9898_a305_5ee346d784a3
  style ae60a6a6_0fc6_e295_3cff_50b6ad3a221d fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

apps/v4/examples/radix/ui/avatar.tsx lines 59–73

function AvatarBadge({ className, ...props }: React.ComponentProps<"span">) {
  return (
    <span
      data-slot="avatar-badge"
      className={cn(
        "bg-primary text-primary-foreground ring-background absolute right-0 bottom-0 z-10 inline-flex items-center justify-center rounded-full bg-blend-color ring-2 select-none",
        "group-data-[size=sm]/avatar:size-2 group-data-[size=sm]/avatar:[&>svg]:hidden",
        "group-data-[size=default]/avatar:size-2.5 group-data-[size=default]/avatar:[&>svg]:size-2",
        "group-data-[size=lg]/avatar:size-3 group-data-[size=lg]/avatar:[&>svg]:size-2",
        className
      )}
      {...props}
    />
  )
}

Subdomains

Frequently Asked Questions

What does AvatarBadge() do?
AvatarBadge() is a function in the ui codebase, defined in apps/v4/examples/radix/ui/avatar.tsx.
Where is AvatarBadge() defined?
AvatarBadge() is defined in apps/v4/examples/radix/ui/avatar.tsx at line 59.

Analyze Your Own Codebase

Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.

Try Supermodel Free