"use client"; import type { ComponentProps } from "react"; import { Check } from "lucide-react"; import { Avatar } from "@/components/ui/avatar"; import { cn } from "@/lib/utils"; type SelectableAvatarProps = ComponentProps & { /** Whether the underlying message/thread is currently selected. */ checked: boolean; /** Toggle selection. The wrapper stops propagation so the row is not opened. */ onToggle: () => void; /** Accessible label for the selection control. */ selectLabel?: string; }; /** * Avatar that doubles as a selection control, Thunderbird-style: clicking the * avatar toggles the message/thread into the current selection instead of * opening it. A check overlay appears on hover (hinting it is clickable) and * stays visible while the row is selected. */ export function SelectableAvatar({ checked, onToggle, selectLabel, className, ...avatarProps }: SelectableAvatarProps) { return ( ); }