This component no longer exists. It was in gmhlab’s manifest when we first indexed it and is not there now — the registry served its inventory on 2026-08-09 and this item was not on it. The install command below will fail. It is kept here because a tutorial somewhere still tells people to run it.
avatar
gmhlab/avatarRemovedComponent
gmhlab publishes no description for this item.
Install it
npx shadcn@latest add https://raw.githubusercontent.com/gmhlab/monorepo/main/packages/ui/public/r/avatar.jsonSource
1import * as React from "react"2import { Avatar as AvatarPrimitive } from "radix-ui"34import { cn } from "@/lib/utils"56function Avatar({7 className,8 size = "default",9 ...props10}: React.ComponentProps<typeof AvatarPrimitive.Root> & {11 size?: "default" | "sm" | "lg"12}) {13 return (14 <AvatarPrimitive.Root15 data-slot="avatar"16 data-size={size}17 className={cn(18 "group/avatar relative flex size-8 shrink-0 overflow-hidden rounded-full select-none data-[size=lg]:size-10 data-[size=sm]:size-6",19 className20 )}21 {...props}22 />23 )24}2526function AvatarImage({27 className,28 ...props29}: React.ComponentProps<typeof AvatarPrimitive.Image>) {30 return (31 <AvatarPrimitive.Image32 data-slot="avatar-image"33 className={cn("aspect-square size-full", className)}34 {...props}35 />36 )37}3839function AvatarFallback({40 className,41 ...props42}: React.ComponentProps<typeof AvatarPrimitive.Fallback>) {43 return (44 <AvatarPrimitive.Fallback45 data-slot="avatar-fallback"46 className={cn(47 "bg-muted text-muted-foreground flex size-full items-center justify-center rounded-full text-sm group-data-[size=sm]/avatar:text-xs",48 className49 )}50 {...props}51 />52 )53}5455function AvatarBadge({ className, ...props }: React.ComponentProps<"span">) {56 return (57 <span58 data-slot="avatar-badge"59 className={cn(60 "bg-primary text-primary-foreground ring-background absolute right-0 bottom-0 z-10 inline-flex items-center justify-center rounded-full ring-2 select-none",61 "group-data-[size=sm]/avatar:size-2 group-data-[size=sm]/avatar:[&>svg]:hidden",62 "group-data-[size=default]/avatar:size-2.5 group-data-[size=default]/avatar:[&>svg]:size-2",63 "group-data-[size=lg]/avatar:size-3 group-data-[size=lg]/avatar:[&>svg]:size-2",64 className65 )}66 {...props}67 />68 )69}7071function AvatarGroup({ className, ...props }: React.ComponentProps<"div">) {72 return (73 <div74 data-slot="avatar-group"75 className={cn(76 "*:data-[slot=avatar]:ring-background group/avatar-group flex -space-x-2 *:data-[slot=avatar]:ring-2",77 className78 )}79 {...props}80 />81 )82}8384function AvatarGroupCount({85 className,86 ...props87}: React.ComponentProps<"div">) {88 return (89 <div90 data-slot="avatar-group-count"91 className={cn(92// … truncated
What it pulls in
npm packages
