Fix locale switch full-page navigation
CI / quality (push) Waiting to run

This commit is contained in:
MOH
2026-03-07 14:48:41 +01:00
parent 917be15dd5
commit f983ce2203
+2 -4
View File
@@ -1,6 +1,5 @@
"use client";
import Link from "next/link";
import { usePathname } from "next/navigation";
import { Button } from "@/components/ui/button";
@@ -22,14 +21,13 @@ export function LocaleToggle({ locale }: LocaleToggleProps) {
<Button
key={targetLocale}
asChild
type="button"
variant={targetLocale === currentLocale ? "secondary" : "outline"}
size="sm"
className="text-xs"
>
<Link href={getLocalizedPath(targetLocale, currentPath)}>
<a href={getLocalizedPath(targetLocale, currentPath)}>
{targetLocale.toUpperCase()}
</Link>
</a>
</Button>
))}
</div>