Skip to content

Commit

Permalink
#129: add new languages
Browse files Browse the repository at this point in the history
  • Loading branch information
brklyn8900 committed Dec 9, 2024
1 parent 5aa565a commit 1622a8c
Show file tree
Hide file tree
Showing 6 changed files with 1,640 additions and 4 deletions.
16 changes: 16 additions & 0 deletions components/layout/Menu.js
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,22 @@ export default function Menu() {
>
Español
</Link>
<Link
href={router.asPath}
locale="it"
className={`d-block px-3 py-1 text-decoration-none text-left ${router.locale === 'es' ? 'active' : ''}`}
onClick={() => setIsLangDropdownOpen(false)}
>
Italiano
</Link>
<Link
href={router.asPath}
locale="fa"
className={`d-block px-3 py-1 text-decoration-none text-left ${router.locale === 'es' ? 'active' : ''}`}
onClick={() => setIsLangDropdownOpen(false)}
>
فارسی
</Link>
</div>
)}
</div>
Expand Down
28 changes: 27 additions & 1 deletion components/layout/MobileMenu.js
Original file line number Diff line number Diff line change
Expand Up @@ -162,7 +162,33 @@ export default function MobileMenu({ handleMobileMenu }) {
}}
>
Español
</Link>
</Link>
</div>
<div>
<Link
href={router.asPath}
locale="it"
className={`d-block py-1 text-decoration-none ${router.locale === 'es' ? 'active' : ''}`}
onClick={() => {
setIsLangDropdownOpen(false)
handleMobileMenu()
}}
>
Italiano
</Link>
</div>
<div>
<Link
href={router.asPath}
locale="fa"
className={`d-block py-1 text-decoration-none ${router.locale === 'es' ? 'active' : ''}`}
onClick={() => {
setIsLangDropdownOpen(false)
handleMobileMenu()
}}
>
فارسی
</Link>
</div>
</div>
)}
Expand Down
Loading

0 comments on commit 1622a8c

Please sign in to comment.