"use client"; import { useLocale, useTranslations } from "next-intl"; import { useRouter, usePathname } from "next-intl/client"; import { Select, SelectContent, SelectItem, SelectTrigger, SelectValue, } from "@/components/ui/select"; export function LanguageSwitcher() { const router = useRouter(); const pathname = usePathname(); const locale = useLocale(); const t = useTranslations("LanguageSwitcher"); const onSelectChange = (value: string) => { router.replace(pathname, { locale: value }); }; return ( ); }