Add Friends page with layout and navigation; update localization for new content
This commit is contained in:
35
src/components/Nav.tsx
Normal file
35
src/components/Nav.tsx
Normal file
@@ -0,0 +1,35 @@
|
||||
import { useTranslation } from 'react-i18next'
|
||||
import { Link } from 'react-router-dom'
|
||||
import LanguageSelector from './LanguageSelector'
|
||||
import ThemeToggle from './ThemeToggle'
|
||||
|
||||
interface NavProps {
|
||||
currentPage?: string
|
||||
}
|
||||
|
||||
function Nav({ currentPage }: NavProps) {
|
||||
const { t } = useTranslation()
|
||||
|
||||
return (
|
||||
<nav className="navbar">
|
||||
<div className="nav-container">
|
||||
<div className="nav-logo">
|
||||
<h2>🎯 {t('nav.logo')}</h2>
|
||||
</div>
|
||||
<div className="nav-links">
|
||||
<a href="/" className={currentPage === 'home' ? 'active' : ''}>{t('nav.home')}</a>
|
||||
<a href="/#servers" className={currentPage === 'servers' ? 'active' : ''}>{t('nav.servers')}</a>
|
||||
<a href="/#blog" className={currentPage === 'blog' ? 'active' : ''}>{t('nav.blog')}</a>
|
||||
<a href="https://git.cialloo.com" className={currentPage === 'git' ? 'active' : ''}>{t('nav.git')}</a>
|
||||
<a href="/#forum" className={currentPage === 'forum' ? 'active' : ''}>{t('nav.forum')}</a>
|
||||
<Link to="/friends" className={currentPage === 'friends' ? 'active' : ''}>{t('nav.friends')}</Link>
|
||||
<ThemeToggle />
|
||||
<LanguageSelector />
|
||||
<button className="join-btn">{t('nav.joinNow')}</button>
|
||||
</div>
|
||||
</div>
|
||||
</nav>
|
||||
)
|
||||
}
|
||||
|
||||
export default Nav
|
||||
Reference in New Issue
Block a user