import { cn } from "~/utils"; import { Avatar } from "./ui/avatar"; import { Button } from "./ui/button"; import { AddIcon, EditIcon, FingerPrintIcon } from "./icons"; import { Dialog, DialogDescription, DialogHeader, DialogTitle, DialogTrigger } from "./ui/dialog"; import { DialogContent, Portal } from "@radix-ui/react-dialog"; interface ManagementCardProps { title?: string; value?: string; subtitle?: string; isInviteCard?: boolean; isPasswordCard?: boolean; isAvatarCard?: boolean; isDeleteCard?: boolean buttonText?: string; buttonOnClick?: () => void dialogNode?: React.ReactNode } export const ManagementCard = ({ title, isAvatarCard, isInviteCard, isPasswordCard, isDeleteCard, subtitle, value, buttonText, buttonOnClick, dialogNode }: ManagementCardProps) => { const buttonVariant: string = isInviteCard ? "accent" : isDeleteCard ? "destructive" : "default"; return (
{isAvatarCard ? (
) : ( <>

{title}

{subtitle && ( {subtitle} )} {value && ( {value} )} {isPasswordCard && } {!dialogNode ? ( ): ( Open Are you absolutely sure? This action cannot be undone. This will permanently delete your account and remove your data from our servers. )} )}
); }; const PasswordDots = ({ className }: { className?: string }) => { return ( ); };