diff --git a/app/[locale]/aktiviteler/page.tsx b/app/[locale]/aktiviteler/page.tsx index 7561276..b80e896 100644 --- a/app/[locale]/aktiviteler/page.tsx +++ b/app/[locale]/aktiviteler/page.tsx @@ -7,7 +7,7 @@ export default async function ActivitiesPage({ params }: { params: Promise<{ loc setRequestLocale(locale); return ( -
+

Aktiviteler

diff --git a/app/[locale]/hakkimizda/page.tsx b/app/[locale]/hakkimizda/page.tsx index 9dc73d8..0440876 100644 --- a/app/[locale]/hakkimizda/page.tsx +++ b/app/[locale]/hakkimizda/page.tsx @@ -5,7 +5,7 @@ export default async function AboutPage({ params }: { params: Promise<{ locale: setRequestLocale(locale); return ( -

+

Hakkımızda

diff --git a/app/[locale]/iletisim/page.tsx b/app/[locale]/iletisim/page.tsx index a6695eb..e822f82 100644 --- a/app/[locale]/iletisim/page.tsx +++ b/app/[locale]/iletisim/page.tsx @@ -7,7 +7,7 @@ export default async function ContactPage({ params }: { params: Promise<{ locale setRequestLocale(locale); return ( -
+

İletişim

diff --git a/app/[locale]/tekne-turlari/page.tsx b/app/[locale]/tekne-turlari/page.tsx index 804ce22..52cb65f 100644 --- a/app/[locale]/tekne-turlari/page.tsx +++ b/app/[locale]/tekne-turlari/page.tsx @@ -7,7 +7,7 @@ export default async function BoatToursPage({ params }: { params: Promise<{ loca setRequestLocale(locale); return ( -

+

Tekne Turları

diff --git a/app/[locale]/turlar/page.tsx b/app/[locale]/turlar/page.tsx index 353c579..fa40d78 100644 --- a/app/[locale]/turlar/page.tsx +++ b/app/[locale]/turlar/page.tsx @@ -7,7 +7,7 @@ export default async function ToursPage({ params }: { params: Promise<{ locale: setRequestLocale(locale); return ( -

+

Turlar

diff --git a/components/home/HeroSlider.tsx b/components/home/HeroSlider.tsx index 2683e47..aa4eb5f 100644 --- a/components/home/HeroSlider.tsx +++ b/components/home/HeroSlider.tsx @@ -5,9 +5,11 @@ import Image from 'next/image'; import { heroSlides } from '@/lib/data'; import { ChevronLeft, ChevronRight } from 'lucide-react'; import { Link } from '@/i18n/routing'; +import { useTranslations } from 'next-intl'; export function HeroSlider() { const [current, setCurrent] = useState(0); + const t = useTranslations('hero'); useEffect(() => { const timer = setInterval(() => { @@ -20,7 +22,7 @@ export function HeroSlider() { const prevSlide = () => setCurrent(current === 0 ? heroSlides.length - 1 : current - 1); return ( -

+
{/* Decorative Aurora Gradients */}
@@ -53,14 +55,14 @@ export function HeroSlider() { ÖLÜDENİZ TOUR TRAVELS

- Mavi Yolculuk, Günübirlik Turlar ve Unutulmaz Aktiviteler + {t('subtitle')}

- Turları Keşfet + {t('exploreTours')} - Aktiviteler + {t('activities')}
diff --git a/components/layout/Navbar.tsx b/components/layout/Navbar.tsx index f88e2e5..8c153b1 100644 --- a/components/layout/Navbar.tsx +++ b/components/layout/Navbar.tsx @@ -1,62 +1,96 @@ 'use client'; -import { Link } from '@/i18n/routing'; +import { Link, usePathname, useRouter } from '@/i18n/routing'; +import { useLocale, useTranslations } from 'next-intl'; import { siteInfo } from '@/lib/data'; -import { Phone, MapPin, Menu } from 'lucide-react'; +import { Phone, Menu, Globe } from 'lucide-react'; import { useState } from 'react'; export function Navbar() { const [isOpen, setIsOpen] = useState(false); + const locale = useLocale(); + const t = useTranslations('nav'); + const router = useRouter(); + const pathname = usePathname(); + + const toggleLocale = () => { + const nextLocale = locale === 'tr' ? 'en' : 'tr'; + router.replace(pathname, { locale: nextLocale }); + }; return ( -
-
-
- +
+
+
+ {siteInfo.name} - {/* Desktop Nav */} - + {/* Desktop Nav */} + -
- - - {siteInfo.phone} - - - Rezervasyon - +
+ {/* Language Switcher */} + + + + + {siteInfo.phone} + + + {t('reservation')} + +
+ + {/* Mobile Toggle */} +
+ + +
- {/* Mobile Toggle */} - -
- - {/* Mobile Nav */} - {isOpen && ( -
- setIsOpen(false)} className="text-sm font-medium">Ana Sayfa - setIsOpen(false)} className="text-sm font-medium">Hakkımızda - setIsOpen(false)} className="text-sm font-medium">Turlar - setIsOpen(false)} className="text-sm font-medium">Aktiviteler - setIsOpen(false)} className="text-sm font-medium">Tekne Turları - setIsOpen(false)} className="text-sm font-medium">İletişim - - Rezervasyon - -
- )} -
+ {/* Mobile Nav */} + {isOpen && ( +
+ setIsOpen(false)} className="text-sm font-medium">{t('home')} + setIsOpen(false)} className="text-sm font-medium">{t('about')} + setIsOpen(false)} className="text-sm font-medium">{t('tours')} + setIsOpen(false)} className="text-sm font-medium">{t('activities')} + setIsOpen(false)} className="text-sm font-medium">{t('boatTours')} + setIsOpen(false)} className="text-sm font-medium">{t('contact')} + + +
+ )} +
); } diff --git a/messages/en.json b/messages/en.json index f793be6..e283384 100644 --- a/messages/en.json +++ b/messages/en.json @@ -2,11 +2,17 @@ "nav": { "home": "Home", "about": "About Us", - "contact": "Contact" + "tours": "Tours", + "activities": "Activities", + "boatTours": "Boat Tours", + "contact": "Contact", + "reservation": "Reservation", + "bookNow": "Book Now" }, "hero": { - "title": "Welcome", - "cta": "Learn More" + "subtitle": "Blue Cruise, Daily Tours and Unforgettable Activities", + "exploreTours": "Explore Tours", + "activities": "Activities" }, "footer": { "rights": "All rights reserved." diff --git a/messages/tr.json b/messages/tr.json index 1994c6c..973c5f0 100644 --- a/messages/tr.json +++ b/messages/tr.json @@ -2,11 +2,17 @@ "nav": { "home": "Ana Sayfa", "about": "Hakkımızda", - "contact": "İletişim" + "tours": "Turlar", + "activities": "Aktiviteler", + "boatTours": "Tekne Turları", + "contact": "İletişim", + "reservation": "Rezervasyon", + "bookNow": "Hemen Rezervasyon Yap" }, "hero": { - "title": "Hoş Geldiniz", - "cta": "Daha Fazla Bilgi" + "subtitle": "Mavi Yolculuk, Günübirlik Turlar ve Unutulmaz Aktiviteler", + "exploreTours": "Turları Keşfet", + "activities": "Aktiviteler" }, "footer": { "rights": "Tüm hakları saklıdır."