"use client"; import { useTranslation } from "react-i18next"; import { Button } from "@/components/ui/button"; import { Popover, PopoverContent, PopoverTrigger, } from "@/components/ui/popover"; import type { BrowserProfile } from "@/types"; export function ProfileUsageButton({ profiles, failed = false, label, }: { profiles: BrowserProfile[] | null; failed?: boolean; label: string; }) { const { t } = useTranslation(); return (

{label}

{profiles?.length ? ( ) : (

{t( profiles ? "appFeedback.noAssignments" : failed ? "appFeedback.referencesFailed" : "common.buttons.loading", )}

)}
); }