Home / File/ avatar-example.tsx — ui Source File

avatar-example.tsx — ui Source File

Architecture documentation for avatar-example.tsx, a tsx file in the ui codebase. 5 imports, 0 dependents.

File tsx ComponentRegistry UIPrimitives 5 imports 8 functions

Entity Profile

Dependency Diagram

graph LR
  da628c9f_c737_5cef_6f42_0c35975bff72["avatar-example.tsx"]
  f56be340_a522_c6f7_dec3_5906873d14c8["example"]
  da628c9f_c737_5cef_6f42_0c35975bff72 --> f56be340_a522_c6f7_dec3_5906873d14c8
  33aff0f4_3c33_c7f6_34d2_7728d844b2e2["avatar"]
  da628c9f_c737_5cef_6f42_0c35975bff72 --> 33aff0f4_3c33_c7f6_34d2_7728d844b2e2
  7328fa0a_98b6_fe77_42fd_0d1582b24604["button"]
  da628c9f_c737_5cef_6f42_0c35975bff72 --> 7328fa0a_98b6_fe77_42fd_0d1582b24604
  55bab6c5_37fc_a32d_630f_04db6fe6cb43["empty"]
  da628c9f_c737_5cef_6f42_0c35975bff72 --> 55bab6c5_37fc_a32d_630f_04db6fe6cb43
  de6fac54_74ca_6c25_8f8b_d1ba3287dbf2["icon-placeholder"]
  da628c9f_c737_5cef_6f42_0c35975bff72 --> de6fac54_74ca_6c25_8f8b_d1ba3287dbf2
  style da628c9f_c737_5cef_6f42_0c35975bff72 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

import {
  Example,
  ExampleWrapper,
} from "@/registry/bases/base/components/example"
import {
  Avatar,
  AvatarBadge,
  AvatarFallback,
  AvatarGroup,
  AvatarGroupCount,
  AvatarImage,
} from "@/registry/bases/base/ui/avatar"
import { Button } from "@/registry/bases/base/ui/button"
import {
  Empty,
  EmptyContent,
  EmptyDescription,
  EmptyHeader,
  EmptyMedia,
  EmptyTitle,
} from "@/registry/bases/base/ui/empty"
import { IconPlaceholder } from "@/app/(create)/components/icon-placeholder"

export default function AvatarExample() {
  return (
    <ExampleWrapper>
      <AvatarSizes />
      <AvatarWithBadge />
      <AvatarWithBadgeIcon />
      <AvatarGroupExample />
      <AvatarGroupWithCount />
      <AvatarGroupWithIconCount />
      <AvatarInEmpty />
    </ExampleWrapper>
  )
}

function AvatarSizes() {
  return (
    <Example title="Sizes">
      <div className="flex flex-wrap items-center gap-2">
        <Avatar size="sm">
          <AvatarImage src="https://github.com/shadcn.png" alt="@shadcn" />
          <AvatarFallback>CN</AvatarFallback>
        </Avatar>
        <Avatar>
          <AvatarImage src="https://github.com/shadcn.png" alt="@shadcn" />
          <AvatarFallback>CN</AvatarFallback>
        </Avatar>
        <Avatar size="lg">
          <AvatarImage src="https://github.com/shadcn.png" alt="@shadcn" />
          <AvatarFallback>CN</AvatarFallback>
        </Avatar>
      </div>
      <div className="flex flex-wrap items-center gap-2">
        <Avatar size="sm">
          <AvatarFallback>CN</AvatarFallback>
        </Avatar>
        <Avatar>
          <AvatarFallback>CN</AvatarFallback>
// ... (452 more lines)

Subdomains

Dependencies

  • avatar
  • button
  • empty
  • example
  • icon-placeholder

Frequently Asked Questions

What does avatar-example.tsx do?
avatar-example.tsx is a source file in the ui codebase, written in tsx. It belongs to the ComponentRegistry domain, UIPrimitives subdomain.
What functions are defined in avatar-example.tsx?
avatar-example.tsx defines 8 function(s): AvatarExample, AvatarGroupExample, AvatarGroupWithCount, AvatarGroupWithIconCount, AvatarInEmpty, AvatarSizes, AvatarWithBadge, AvatarWithBadgeIcon.
What does avatar-example.tsx depend on?
avatar-example.tsx imports 5 module(s): avatar, button, empty, example, icon-placeholder.
Where is avatar-example.tsx in the architecture?
avatar-example.tsx is located at apps/v4/registry/bases/base/examples/avatar-example.tsx (domain: ComponentRegistry, subdomain: UIPrimitives, directory: apps/v4/registry/bases/base/examples).

Analyze Your Own Codebase

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

Try Supermodel Free