import { m } from "framer-motion"; import { useTranslation } from "react-i18next"; import { cn } from "@/lib/utils"; export default function TabSwitch({ tabs, currentTab, setCurrentTab, }: { tabs: string[]; currentTab: string; setCurrentTab: (tab: string) => void; }) { const { t } = useTranslation(); const customBackgroundImage = (window.CustomBackgroundImage as string) !== "" ? window.CustomBackgroundImage : undefined; return (
{tabs.map((tab: string) => (
setCurrentTab(tab)} className={cn( "relative cursor-pointer rounded-3xl px-2.5 py-[8px] text-[13px] font-semibold transition-all duration-500", currentTab === tab ? "text-black dark:text-white" : "text-stone-400 dark:text-stone-500", )} > {currentTab === tab && ( )}

{t(`tabSwitch.${tab}`)}

))}
); }