feat: optimize event capturing and playback accuracy

This commit is contained in:
2026-02-15 18:06:50 +01:00
parent e615d88fd8
commit a136e7b4a7
38 changed files with 2847 additions and 523 deletions

View File

@@ -46,10 +46,22 @@ export default function Header() {
return segments.join('/');
};
const [productsSlug, setProductsSlug] = useState('products');
useEffect(() => {
// We can't use mapFileSlugToTranslated directly in client components easily without an API or similar
// For now, let's just check the locale
if (currentLocale === 'de') {
setProductsSlug('produkte');
} else {
setProductsSlug('products');
}
}, [currentLocale]);
const menuItems = [
{ label: t('home'), href: '/' },
{ label: t('team'), href: '/team' },
{ label: t('products'), href: '/products' },
{ label: t('products'), href: `/${productsSlug}` },
{ label: t('blog'), href: '/blog' },
];