added multi language features

This commit is contained in:
nabijonovdavronbek619@gmail.com
2026-03-31 19:45:21 +05:00
parent 4f3d73443f
commit 291375ce02
19 changed files with 728 additions and 246 deletions

View File

@@ -11,16 +11,19 @@ import {
import SubMenuLink from './SubMenuLink';
import { ChangeLang } from './ChangeLang';
import { useLoginModal, useRegisterModal } from '@/shared/zustand/auth';
import { useTranslations } from 'next-intl';
function AuthButtons() {
const t = useTranslations('Navbar');
const auth = {
login: { title: 'Login', url: '#' },
signup: { title: 'Sign up', url: '#' },
login: { title: t('login'), url: '#' },
signup: { title: t('signup'), url: '#' },
};
const userItem = [
{ title: 'Profile', url: '/profile' },
{ title: 'Logout', url: '#' },
{ title: t('profile'), url: '/profile' },
{ title: t('logout'), url: '#' },
];
const toggleLoginModal = useLoginModal((state) => state.toggleLoginModal);