A quick vibe-coded site to test response times of PLC.directory mirrors (over 3 attempts)
1import * as React from "react";
2import * as AvatarPrimitive from "@radix-ui/react-avatar";
3
4import { cn } from "@/lib/utils";
5
6const Avatar = React.forwardRef<
7 React.ElementRef<typeof AvatarPrimitive.Root>,
8 React.ComponentPropsWithoutRef<typeof AvatarPrimitive.Root>
9>(({ className, ...props }, ref) => (
10 <AvatarPrimitive.Root
11 ref={ref}
12 className={cn("relative flex h-10 w-10 shrink-0 overflow-hidden rounded-full", className)}
13 {...props}
14 />
15));
16Avatar.displayName = AvatarPrimitive.Root.displayName;
17
18const AvatarImage = React.forwardRef<
19 React.ElementRef<typeof AvatarPrimitive.Image>,
20 React.ComponentPropsWithoutRef<typeof AvatarPrimitive.Image>
21>(({ className, ...props }, ref) => (
22 <AvatarPrimitive.Image ref={ref} className={cn("aspect-square h-full w-full", className)} {...props} />
23));
24AvatarImage.displayName = AvatarPrimitive.Image.displayName;
25
26const AvatarFallback = React.forwardRef<
27 React.ElementRef<typeof AvatarPrimitive.Fallback>,
28 React.ComponentPropsWithoutRef<typeof AvatarPrimitive.Fallback>
29>(({ className, ...props }, ref) => (
30 <AvatarPrimitive.Fallback
31 ref={ref}
32 className={cn("flex h-full w-full items-center justify-center rounded-full bg-muted", className)}
33 {...props}
34 />
35));
36AvatarFallback.displayName = AvatarPrimitive.Fallback.displayName;
37
38export { Avatar, AvatarImage, AvatarFallback };