Skip to content

Commit 764d3c9

Browse files
committed
localize Footer component
1 parent 8980fdd commit 764d3c9

4 files changed

Lines changed: 27 additions & 4 deletions

File tree

frontend/components/shared/Footer.tsx

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,9 @@
1+
'use client';
2+
13
import Link from 'next/link';
24
import { Github, Linkedin, Send } from 'lucide-react';
35
import { ThemeToggle } from '@/components/theme/ThemeToggle';
6+
import { useTranslations } from 'next-intl';
47

58
const SOCIAL = [
69
{ label: 'GitHub', href: 'https://github.com/DevLoversTeam', Icon: Github },
@@ -13,6 +16,8 @@ const SOCIAL = [
1316
] as const;
1417

1518
export default function Footer() {
19+
const t = useTranslations('footer');
20+
1621
return (
1722
<footer className="relative overflow-hidden border-t border-gray-200/70 dark:border-neutral-800/70">
1823
<div
@@ -39,26 +44,26 @@ export default function Footer() {
3944
<div className="flex flex-col gap-4 sm:flex-row sm:items-center sm:justify-between">
4045
<div className="space-y-3">
4146
<p className="text-sm text-slate-700 dark:text-slate-200">
42-
Built with{' '}
47+
{t('builtWith')}{' '}
4348
<span className="font-semibold text-blue-600 dark:text-blue-400">
4449
DevLovers
4550
</span>{' '}
46-
by the community.
51+
{t('byCommunity')}
4752
</p>
4853

4954
<p className="text-sm text-slate-500 dark:text-slate-400">
5055
<Link
5156
href="/privacy-policy"
5257
className="hover:text-blue-600 dark:hover:text-blue-400 transition-colors"
5358
>
54-
Privacy Policy
59+
{t('privacyPolicy')}
5560
</Link>
5661
<span className="px-2 opacity-60">|</span>
5762
<Link
5863
href="/terms-of-service"
5964
className="hover:text-blue-600 dark:hover:text-blue-400 transition-colors"
6065
>
61-
Terms of Service
66+
{t('termsOfService')}
6267
</Link>
6368
</p>
6469
</div>

frontend/messages/en.json

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,12 @@
5252
"noPosts": "No posts found",
5353
"noPostsForTags": "No posts found for selected tags"
5454
},
55+
"footer": {
56+
"builtWith": "Built with",
57+
"byCommunity": "by the community.",
58+
"privacyPolicy": "Privacy Policy",
59+
"termsOfService": "Terms of Service"
60+
},
5561
"about": {
5662
"hero": {
5763
"badge": "Our Story",

frontend/messages/pl.json

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,12 @@
5252
"noPosts": "Nie znaleziono wpisów",
5353
"noPostsForTags": "Nie znaleziono wpisów dla wybranych tagów"
5454
},
55+
"footer": {
56+
"builtWith": "Zbudowane z",
57+
"byCommunity": "przez społeczność.",
58+
"privacyPolicy": "Polityka Prywatności",
59+
"termsOfService": "Warunki Świadczenia Usług"
60+
},
5561
"about": {
5662
"hero": {
5763
"badge": "Nasza Historia",

frontend/messages/uk.json

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,12 @@
5252
"noPosts": "Статей не знайдено",
5353
"noPostsForTags": "Немає статей за обраними тегами"
5454
},
55+
"footer": {
56+
"builtWith": "Створено",
57+
"byCommunity": "спільнотою.",
58+
"privacyPolicy": "Політика Конфіденційності",
59+
"termsOfService": "Умови Використання"
60+
},
5561
"about": {
5662
"hero": {
5763
"badge": "Наша Історія",

0 commit comments

Comments
 (0)