Merge version_4 into main #3

Merged
bender merged 8 commits from version_4 into main 2026-03-09 00:54:45 +00:00
8 changed files with 557 additions and 1500 deletions

File diff suppressed because it is too large Load Diff

View File

@@ -13,21 +13,22 @@ import SocialProofOne from "@/components/sections/socialProof/SocialProofOne";
import FaqSplitText from "@/components/sections/faq/FaqSplitText";
import FooterBaseReveal from "@/components/sections/footer/FooterBaseReveal";
import { Star, Globe } from "lucide-react";
import { useTranslation } from "@/hooks/useTranslation";
export default function HomePage() {
const { t } = useTranslation();
const navItems = [
{ name: "Home", id: "/" },
{ name: "Menu", id: "/menu" },
{ name: "Services", id: "services" },
{ name: "Contact", id: "contact" },
{ name: "About", id: "why-us" },
{ name: t("nav.home"), id: "/" },
{ name: t("nav.menu"), id: "/menu" },
{ name: t("nav.services"), id: "services" },
{ name: t("nav.contact"), id: "contact" },
{ name: t("nav.about"), id: "why-us" },
{ name: "🇸🇼 Kiswahili", id: "#" },
];
const handleLanguageChange = (language: string) => {
// Store language preference
localStorage.setItem('preferredLanguage', language);
// Trigger page reload or language change
localStorage.setItem("preferredLanguage", language);
window.location.reload();
};
@@ -47,29 +48,37 @@ export default function HomePage() {
<div id="nav" data-section="nav">
<NavbarStyleFullscreen
navItems={navItems}
brandName="Kzone Cafe & Grill"
bottomLeftText="Mnadani, Kigamboni"
bottomRightText="0655 311 355"
brandName={t("brand.name")}
bottomLeftText={t("brand.location")}
bottomRightText={t("brand.phone")}
/>
</div>
<div id="hero" data-section="hero">
<HeroCarouselLogo
logoText="KZONE"
description="Fresh Food, Anytime Open 24 Hours in Kigamboni. Dine-in, Drive-through, or Delivery. Rated 4.7★ with 38 Customer Reviews."
logoText={t("hero.logo")}
description={t("hero.description")}
buttons={[
{
text: "📞 Call Now", href: "tel:0655311355"},
text: t("hero.callButton"),
href: "tel:0655311355"},
{
text: "🍽 Order Food", href: "https://wa.me/255655311355"},
text: t("hero.orderButton"),
href: "https://wa.me/255655311355"},
]}
slides={[
{
imageSrc: "http://img.b2bpic.net/free-photo/pork-barbecue-cooked-grilled-charcoal-barbecue-is-beautiful-meat-fire-meat-coals_132075-13607.jpg", imageAlt: "Grilled Chicken - Kzone Cafe"},
imageSrc:
"http://img.b2bpic.net/free-photo/pork-barbecue-cooked-grilled-charcoal-barbecue-is-beautiful-meat-fire-meat-coals_132075-13607.jpg", imageAlt: t("hero.slide1Alt"),
},
{
imageSrc: "http://img.b2bpic.net/free-photo/young-couple-having-drinks-party_23-2148037653.jpg", imageAlt: "Restaurant Interior - Kzone Cafe"},
imageSrc:
"http://img.b2bpic.net/free-photo/young-couple-having-drinks-party_23-2148037653.jpg", imageAlt: t("hero.slide2Alt"),
},
{
imageSrc: "http://img.b2bpic.net/free-photo/homemade-delicious-sandwich-fries-chicken-nuggets-black-board-fries-pepper-dark-gray-blurred-surface_179666-42621.jpg?_wi=1", imageAlt: "Burger & Chips - Kzone Cafe"},
imageSrc:
"http://img.b2bpic.net/free-photo/homemade-delicious-sandwich-fries-chicken-nuggets-black-board-fries-pepper-dark-gray-blurred-surface_179666-42621.jpg?_wi=1", imageAlt: t("hero.slide3Alt"),
},
]}
autoplayDelay={5000}
showDimOverlay={true}
@@ -78,19 +87,37 @@ export default function HomePage() {
<div id="services" data-section="services">
<FeatureCardTwentyThree
tag="Services"
title="How We Serve You"
description="Kzone Cafe & Grill offers multiple convenient ways to enjoy our fresh food and excellent service."
tag={t("services.tag")}
title={t("services.title")}
description={t("services.description")}
features={[
{
id: "1", title: "Dine-In Experience", tags: ["Comfortable Seating", "Friendly Staff"],
imageSrc: "http://img.b2bpic.net/free-photo/happy-smiling-bartender-barista-using-coffee-machine-prepare-order-making-cappuccino-latte_1258-203406.jpg?_wi=1", imageAlt: "Restaurant Dining Experience"},
id: "1", title: t("services.feature1Title"),
tags: [
t("services.feature1Tag1"),
t("services.feature1Tag2"),
],
imageSrc:
"http://img.b2bpic.net/free-photo/happy-smiling-bartender-barista-using-coffee-machine-prepare-order-making-cappuccino-latte_1258-203406.jpg?_wi=1", imageAlt: t("services.feature1Alt"),
},
{
id: "2", title: "Drive-Through Service", tags: ["Quick Service", "No Contact"],
imageSrc: "http://img.b2bpic.net/free-photo/young-adults-traveling-london_23-2149259470.jpg?_wi=1", imageAlt: "Drive-Through Service"},
id: "2", title: t("services.feature2Title"),
tags: [
t("services.feature2Tag1"),
t("services.feature2Tag2"),
],
imageSrc:
"http://img.b2bpic.net/free-photo/young-adults-traveling-london_23-2149259470.jpg?_wi=1", imageAlt: t("services.feature2Alt"),
},
{
id: "3", title: "Fast Delivery", tags: ["Same Day", "Reliable"],
imageSrc: "http://img.b2bpic.net/free-photo/delivery-concept-portrait-handsome-african-american-pizza-delivery-man-isolated-grey-studio-background-copy-space_1258-102231.jpg?_wi=1", imageAlt: "Fast Delivery Service"},
id: "3", title: t("services.feature3Title"),
tags: [
t("services.feature3Tag1"),
t("services.feature3Tag2"),
],
imageSrc:
"http://img.b2bpic.net/free-photo/delivery-concept-portrait-handsome-african-american-pizza-delivery-man-isolated-grey-studio-background-copy-space_1258-102231.jpg?_wi=1", imageAlt: t("services.feature3Alt"),
},
]}
animationType="slide-up"
textboxLayout="default"
@@ -100,27 +127,57 @@ export default function HomePage() {
<div id="trust" data-section="trust">
<TestimonialCardTwo
tag="Reviews"
title="Loved by Kigamboni Community"
description="See what our satisfied customers have to say about Kzone Cafe & Grill."
tag={t("testimonials.tag")}
title={t("testimonials.title")}
description={t("testimonials.description")}
testimonials={[
{
id: "1", name: "Fatima Hassan", role: "Local Resident", testimonial: "Sehemu nzuri ya kutulia na familia. Chakula chao kina ladha nzuri sana na huduma ni nzuri.", imageSrc: "http://img.b2bpic.net/free-photo/portrait-beautiful-woman-park-by-red-leaves_1303-22124.jpg", imageAlt: "Fatima Hassan Portrait", icon: Star,
id: "1", name: t("testimonials.testimonial1Name"),
role: t("testimonials.testimonial1Role"),
testimonial: t("testimonials.testimonial1Text"),
imageSrc:
"http://img.b2bpic.net/free-photo/portrait-beautiful-woman-park-by-red-leaves_1303-22124.jpg", imageAlt: t("testimonials.testimonial1Alt"),
icon: Star,
},
{
id: "2", name: "James Mwangi", role: "Business Owner", testimonial: "The best grill restaurant in Kigamboni. Quick service, affordable prices, and excellent quality. Highly recommended!", imageSrc: "http://img.b2bpic.net/free-photo/young-businessman-happy-expression_1194-1689.jpg", imageAlt: "James Mwangi Portrait", icon: Star,
id: "2", name: t("testimonials.testimonial2Name"),
role: t("testimonials.testimonial2Role"),
testimonial: t("testimonials.testimonial2Text"),
imageSrc:
"http://img.b2bpic.net/free-photo/young-businessman-happy-expression_1194-1689.jpg", imageAlt: t("testimonials.testimonial2Alt"),
icon: Star,
},
{
id: "3", name: "Amina Mohammed", role: "Regular Customer", testimonial: "Open 24 hours is perfect for my late-night schedule. Food is always fresh and the staff is always friendly.", imageSrc: "http://img.b2bpic.net/free-photo/mature-woman-striped-shirt-clenching-teeth-looking-troubled-front-view_176474-52779.jpg", imageAlt: "Amina Mohammed Portrait", icon: Star,
id: "3", name: t("testimonials.testimonial3Name"),
role: t("testimonials.testimonial3Role"),
testimonial: t("testimonials.testimonial3Text"),
imageSrc:
"http://img.b2bpic.net/free-photo/mature-woman-striped-shirt-clenching-teeth-looking-troubled-front-view_176474-52779.jpg", imageAlt: t("testimonials.testimonial3Alt"),
icon: Star,
},
{
id: "4", name: "David Kipchoge", role: "Student", testimonial: "Best place to hang out with friends. Great food, good prices, and wonderful atmosphere. Love it!", imageSrc: "http://img.b2bpic.net/free-photo/closeup-portrait-cheerful-attractive-young-male-student-showing-promo-pointing-upper-left-corn_1258-109454.jpg", imageAlt: "David Kipchoge Portrait", icon: Star,
id: "4", name: t("testimonials.testimonial4Name"),
role: t("testimonials.testimonial4Role"),
testimonial: t("testimonials.testimonial4Text"),
imageSrc:
"http://img.b2bpic.net/free-photo/closeup-portrait-cheerful-attractive-young-male-student-showing-promo-pointing-upper-left-corn_1258-109454.jpg", imageAlt: t("testimonials.testimonial4Alt"),
icon: Star,
},
{
id: "5", name: "Sarah Mwangi", role: "Working Professional", testimonial: "Convenient drive-through service saves me time. Delivery is fast and food quality is consistent every time.", imageSrc: "http://img.b2bpic.net/free-photo/young-woman-with-glasses-laughing_23-2148415938.jpg", imageAlt: "Sarah Mwangi Portrait", icon: Star,
id: "5", name: t("testimonials.testimonial5Name"),
role: t("testimonials.testimonial5Role"),
testimonial: t("testimonials.testimonial5Text"),
imageSrc:
"http://img.b2bpic.net/free-photo/young-woman-with-glasses-laughing_23-2148415938.jpg", imageAlt: t("testimonials.testimonial5Alt"),
icon: Star,
},
{
id: "6", name: "Peter Ochieng", role: "Family Man", testimonial: "Family favorite! Kids love the chips and chicken, adults appreciate the value for money. Perfect for family outings.", imageSrc: "http://img.b2bpic.net/free-photo/smiling-dad-dancing-with-daughter_23-2147800128.jpg", imageAlt: "Peter Ochieng Portrait", icon: Star,
id: "6", name: t("testimonials.testimonial6Name"),
role: t("testimonials.testimonial6Role"),
testimonial: t("testimonials.testimonial6Text"),
imageSrc:
"http://img.b2bpic.net/free-photo/smiling-dad-dancing-with-daughter_23-2147800128.jpg", imageAlt: t("testimonials.testimonial6Alt"),
icon: Star,
},
]}
animationType="slide-up"
@@ -132,18 +189,34 @@ export default function HomePage() {
<div id="menu" data-section="menu">
<ProductCardOne
tag="Popular Menu"
title="Featured Foods"
description="Taste our most popular menu items - fresh, delicious, and affordable. View the full menu for more options."
tag={t("menu.tag")}
title={t("menu.title")}
description={t("menu.description")}
products={[
{
id: "1", name: "Grilled Chicken", price: "From 8,000 TZS", imageSrc: "http://img.b2bpic.net/free-photo/top-view-fried-chicken-tomatoes-lemon-slices-oval-plate-table-free-space_140725-147488.jpg?_wi=1", imageAlt: "Grilled Chicken"},
id: "1", name: t("menu.product1Name"),
price: t("menu.product1Price"),
imageSrc:
"http://img.b2bpic.net/free-photo/top-view-fried-chicken-tomatoes-lemon-slices-oval-plate-table-free-space_140725-147488.jpg?_wi=1", imageAlt: t("menu.product1Alt"),
},
{
id: "2", name: "Juicy Burger", price: "From 6,000 TZS", imageSrc: "http://img.b2bpic.net/free-photo/making-homemade-burger-ingredients-cooking-wooden-tabletop-view-flat-lay-copy-space_127032-3012.jpg?_wi=1", imageAlt: "Juicy Burger"},
id: "2", name: t("menu.product2Name"),
price: t("menu.product2Price"),
imageSrc:
"http://img.b2bpic.net/free-photo/making-homemade-burger-ingredients-cooking-wooden-tabletop-view-flat-lay-copy-space_127032-3012.jpg?_wi=1", imageAlt: t("menu.product2Alt"),
},
{
id: "3", name: "Fresh Chips", price: "From 3,000 TZS", imageSrc: "http://img.b2bpic.net/free-photo/young-adult-enjoying-food_23-2149303526.jpg?_wi=1", imageAlt: "Fresh Chips"},
id: "3", name: t("menu.product3Name"),
price: t("menu.product3Price"),
imageSrc:
"http://img.b2bpic.net/free-photo/young-adult-enjoying-food_23-2149303526.jpg?_wi=1", imageAlt: t("menu.product3Alt"),
},
{
id: "4", name: "Cool Drinks", price: "From 2,000 TZS", imageSrc: "http://img.b2bpic.net/free-photo/fruit-cocktail-glass-cafe_1339-7258.jpg?_wi=1", imageAlt: "Cool Drinks"},
id: "4", name: t("menu.product4Name"),
price: t("menu.product4Price"),
imageSrc:
"http://img.b2bpic.net/free-photo/fruit-cocktail-glass-cafe_1339-7258.jpg?_wi=1", imageAlt: t("menu.product4Alt"),
},
]}
gridVariant="four-items-2x2-equal-grid"
animationType="slide-up"
@@ -151,32 +224,41 @@ export default function HomePage() {
useInvertedBackground={false}
buttons={[
{
text: "View Full Menu", href: "/menu"},
text: t("menu.viewFullMenuButton"),
href: "/menu"},
]}
/>
</div>
<div id="why-us" data-section="why-us">
<TextAbout
tag="Why Choose Us"
title="Kzone Cafe & Grill: Your Favorite Local Restaurant. Open 24 Hours with Quick Service, Affordable Prices, Friendly Environment, and Community Trust."
tag={t("whyUs.tag")}
title={t("whyUs.title")}
useInvertedBackground={false}
buttons={[
{
text: "Reserve a Table", href: "#contact"},
text: t("whyUs.reserveButton"),
href: "#contact"},
{
text: "Order Now", href: "https://wa.me/255655311355"},
text: t("whyUs.orderButton"),
href: "https://wa.me/255655311355"},
]}
/>
</div>
<div id="social-proof" data-section="social-proof">
<SocialProofOne
title="Trusted by Kigamboni Community"
description="Join thousands of satisfied customers who choose Kzone Cafe & Grill daily."
tag="Community Trust"
title={t("socialProof.title")}
description={t("socialProof.description")}
tag={t("socialProof.tag")}
names={[
"Google Reviews: 4.7★", "38+ Customer Reviews", "24/7 Service", "Local Favorite", "Fast Delivery", "Quality Guaranteed"]}
t("socialProof.proof1"),
t("socialProof.proof2"),
t("socialProof.proof3"),
t("socialProof.proof4"),
t("socialProof.proof5"),
t("socialProof.proof6"),
]}
textboxLayout="default"
useInvertedBackground={false}
speed={40}
@@ -186,13 +268,15 @@ export default function HomePage() {
<div id="contact" data-section="contact">
<ContactText
text="Ready to enjoy delicious food? Call us now at 0655 311 355 or order online through WhatsApp. We're open 24 hours every day!"
text={t("contact.text")}
animationType="reveal-blur"
buttons={[
{
text: "📞 Call: 0655 311 355", href: "tel:0655311355"},
text: t("contact.callButton"),
href: "tel:0655311355"},
{
text: "💬 WhatsApp Order", href: "https://wa.me/255655311355"},
text: t("contact.whatsappButton"),
href: "https://wa.me/255655311355"},
]}
background={{
variant: "plain"}}
@@ -202,21 +286,33 @@ export default function HomePage() {
<div id="faq" data-section="faq">
<FaqSplitText
sideTitle="Frequently Asked Questions"
sideDescription="Everything you need to know about Kzone Cafe & Grill services, hours, and ordering."
sideTitle={t("faq.sideTitle")}
sideDescription={t("faq.sideDescription")}
faqs={[
{
id: "1", title: "What are your operating hours?", content: "We are open 24 hours every day! Whether you want breakfast, lunch, dinner, or a late-night snack, we're here for you."},
id: "1", title: t("faq.question1Title"),
content: t("faq.question1Content"),
},
{
id: "2", title: "Do you offer delivery?", content: "Yes! We offer fast, reliable delivery. Call us at 0655 311 355 or order through WhatsApp. Delivery is available throughout Kigamboni and surrounding areas."},
id: "2", title: t("faq.question2Title"),
content: t("faq.question2Content"),
},
{
id: "3", title: "What is your drive-through process?", content: "Simply drive to our location in Mnadani, Kigamboni. You can order from your car and we'll prepare your food quickly for no-contact pickup."},
id: "3", title: t("faq.question3Title"),
content: t("faq.question3Content"),
},
{
id: "4", title: "Can I make reservations?", content: "Yes! For group bookings or reservations, please call us at 0655 311 355. We're happy to accommodate your dining needs."},
id: "4", title: t("faq.question4Title"),
content: t("faq.question4Content"),
},
{
id: "5", title: "What payment methods do you accept?", content: "We accept cash and mobile money payments (M-Pesa, Airtel Money). Contact us for payment details or online ordering options."},
id: "5", title: t("faq.question5Title"),
content: t("faq.question5Content"),
},
{
id: "6", title: "Are there dietary options?", content: "Yes! We offer various menu options including grilled items, vegetarian sides, and fresh drinks. Contact us to discuss specific dietary requirements."},
id: "6", title: t("faq.question6Title"),
content: t("faq.question6Content"),
},
]}
textPosition="left"
useInvertedBackground={false}
@@ -229,39 +325,51 @@ export default function HomePage() {
<FooterBaseReveal
columns={[
{
title: "Location", items: [
title: t("footer.locationTitle"),
items: [
{
label: "Mnadani, Kigamboni, Dar es Salaam", href: "https://maps.google.com/?q=Kzone+Cafe+Grill+Kigamboni"},
label: t("footer.locationAddress"),
href: "https://maps.google.com/?q=Kzone+Cafe+Grill+Kigamboni"},
{
label: "View on Google Maps", href: "https://maps.google.com/?q=Kzone+Cafe+Grill+Kigamboni"},
label: t("footer.locationMap"),
href: "https://maps.google.com/?q=Kzone+Cafe+Grill+Kigamboni"},
],
},
{
title: "Contact", items: [
title: t("footer.contactTitle"),
items: [
{
label: "Phone: 0655 311 355", href: "tel:0655311355"},
label: t("footer.contactPhone"),
href: "tel:0655311355"},
{
label: "WhatsApp Order", href: "https://wa.me/255655311355"},
label: t("footer.contactWhatsapp"),
href: "https://wa.me/255655311355"},
{
label: "Hours: Open 24/7", href: "#"},
label: t("footer.contactHours"),
href: "#"},
],
},
{
title: "Services", items: [
title: t("footer.servicesTitle"),
items: [
{
label: "Dine-In", href: "#services"},
label: t("footer.servicesDineIn"),
href: "#services"},
{
label: "Drive-Through", href: "#services"},
label: t("footer.servicesDriveThrough"),
href: "#services"},
{
label: "Delivery", href: "#services"},
label: t("footer.servicesDelivery"),
href: "#services"},
{
label: "Reservations", href: "#contact"},
label: t("footer.servicesReservations"),
href: "#contact"},
],
},
]}
copyrightText="© 2025 Kzone Cafe & Grill. All rights reserved. Serving Kigamboni with Fresh Food 24/7."
copyrightText={t("footer.copyright")}
/>
</div>
</ThemeProvider>
);
}
}

View File

@@ -0,0 +1,63 @@
"use client";
import { useState } from "react";
import { Globe } from "lucide-react";
interface LanguageToggleProps {
currentLanguage: string;
onLanguageChange: (language: string) => void;
}
const LANGUAGES = [
{ code: "en", name: "English", flag: "🇺🇸" },
{ code: "sw", name: "Kiswahili", flag: "🇹🇿" },
];
export default function LanguageToggle({
currentLanguage,
onLanguageChange,
}: LanguageToggleProps) {
const [isOpen, setIsOpen] = useState(false);
const currentLang = LANGUAGES.find((lang) => lang.code === currentLanguage);
return (
<div className="fixed top-4 right-4 z-50">
<div className="relative">
<button
onClick={() => setIsOpen(!isOpen)}
className="flex items-center gap-2 px-4 py-2 rounded-full bg-white dark:bg-gray-900 border border-gray-200 dark:border-gray-700 hover:bg-gray-50 dark:hover:bg-gray-800 transition-colors shadow-md"
aria-label="Toggle language menu"
aria-expanded={isOpen}
>
<Globe size={18} />
<span className="text-sm font-medium">
{currentLang?.flag} {currentLang?.name}
</span>
</button>
{isOpen && (
<div className="absolute top-full right-0 mt-2 bg-white dark:bg-gray-900 border border-gray-200 dark:border-gray-700 rounded-lg shadow-lg overflow-hidden">
{LANGUAGES.map((lang) => (
<button
key={lang.code}
onClick={() => {
onLanguageChange(lang.code);
setIsOpen(false);
}}
className={`w-full px-4 py-2 text-left text-sm hover:bg-gray-100 dark:hover:bg-gray-800 transition-colors ${
currentLanguage === lang.code
? "bg-gray-50 dark:bg-gray-800 font-semibold"
: ""
}`}
>
<span className="mr-2">{lang.flag}</span>
{lang.name}
</button>
))}
</div>
)}
</div>
</div>
);
}

View File

@@ -0,0 +1,81 @@
import { useEffect, useState } from "react";
const translations = {
en: {
"nav.home": "Home", "nav.menu": "Menu", "nav.services": "Services", "nav.contact": "Contact", "nav.about": "About", "brand.name": "Kzone Cafe & Grill", "brand.location": "Mnadani, Kigamboni", "brand.phone": "0655 311 355", "hero.logo": "KZONE", "hero.description":
"Fresh Food, Anytime Open 24 Hours in Kigamboni. Dine-in, Drive-through, or Delivery. Rated 4.7★ with 38 Customer Reviews.", "hero.callButton": "📞 Call Now", "hero.orderButton": "🍽 Order Food", "hero.slide1Alt": "Grilled Chicken - Kzone Cafe", "hero.slide2Alt": "Restaurant Interior - Kzone Cafe", "hero.slide3Alt": "Burger & Chips - Kzone Cafe", "services.tag": "Services", "services.title": "How We Serve You", "services.description":
"Kzone Cafe & Grill offers multiple convenient ways to enjoy our fresh food and excellent service.", "services.feature1Title": "Dine-In Experience", "services.feature1Tag1": "Comfortable Seating", "services.feature1Tag2": "Friendly Staff", "services.feature1Alt": "Restaurant Dining Experience", "services.feature2Title": "Drive-Through Service", "services.feature2Tag1": "Quick Service", "services.feature2Tag2": "No Contact", "services.feature2Alt": "Drive-Through Service", "services.feature3Title": "Fast Delivery", "services.feature3Tag1": "Same Day", "services.feature3Tag2": "Reliable", "services.feature3Alt": "Fast Delivery Service", "testimonials.tag": "Reviews", "testimonials.title": "Loved by Kigamboni Community", "testimonials.description":
"See what our satisfied customers have to say about Kzone Cafe & Grill.", "testimonials.testimonial1Name": "Fatima Hassan", "testimonials.testimonial1Role": "Local Resident", "testimonials.testimonial1Text":
"Sehemu nzuri ya kutulia na familia. Chakula chao kina ladha nzuri sana na huduma ni nzuri.", "testimonials.testimonial1Alt": "Fatima Hassan Portrait", "testimonials.testimonial2Name": "James Mwangi", "testimonials.testimonial2Role": "Business Owner", "testimonials.testimonial2Text":
"The best grill restaurant in Kigamboni. Quick service, affordable prices, and excellent quality. Highly recommended!", "testimonials.testimonial2Alt": "James Mwangi Portrait", "testimonials.testimonial3Name": "Amina Mohammed", "testimonials.testimonial3Role": "Regular Customer", "testimonials.testimonial3Text":
"Open 24 hours is perfect for my late-night schedule. Food is always fresh and the staff is always friendly.", "testimonials.testimonial3Alt": "Amina Mohammed Portrait", "testimonials.testimonial4Name": "David Kipchoge", "testimonials.testimonial4Role": "Student", "testimonials.testimonial4Text":
"Best place to hang out with friends. Great food, good prices, and wonderful atmosphere. Love it!", "testimonials.testimonial4Alt": "David Kipchoge Portrait", "testimonials.testimonial5Name": "Sarah Mwangi", "testimonials.testimonial5Role": "Working Professional", "testimonials.testimonial5Text":
"Convenient drive-through service saves me time. Delivery is fast and food quality is consistent every time.", "testimonials.testimonial5Alt": "Sarah Mwangi Portrait", "testimonials.testimonial6Name": "Peter Ochieng", "testimonials.testimonial6Role": "Family Man", "testimonials.testimonial6Text":
"Family favorite! Kids love the chips and chicken, adults appreciate the value for money. Perfect for family outings.", "testimonials.testimonial6Alt": "Peter Ochieng Portrait", "menu.tag": "Popular Menu", "menu.title": "Featured Foods", "menu.description":
"Taste our most popular menu items - fresh, delicious, and affordable. View the full menu for more options.", "menu.product1Name": "Grilled Chicken", "menu.product1Price": "From 8,000 TZS", "menu.product1Alt": "Grilled Chicken", "menu.product2Name": "Juicy Burger", "menu.product2Price": "From 6,000 TZS", "menu.product2Alt": "Juicy Burger", "menu.product3Name": "Fresh Chips", "menu.product3Price": "From 3,000 TZS", "menu.product3Alt": "Fresh Chips", "menu.product4Name": "Cool Drinks", "menu.product4Price": "From 2,000 TZS", "menu.product4Alt": "Cool Drinks", "menu.viewFullMenuButton": "View Full Menu", "whyUs.tag": "Why Choose Us", "whyUs.title":
"Kzone Cafe & Grill: Your Favorite Local Restaurant. Open 24 Hours with Quick Service, Affordable Prices, Friendly Environment, and Community Trust.", "whyUs.reserveButton": "Reserve a Table", "whyUs.orderButton": "Order Now", "socialProof.title": "Trusted by Kigamboni Community", "socialProof.description":
"Join thousands of satisfied customers who choose Kzone Cafe & Grill daily.", "socialProof.tag": "Community Trust", "socialProof.proof1": "Google Reviews: 4.7★", "socialProof.proof2": "38+ Customer Reviews", "socialProof.proof3": "24/7 Service", "socialProof.proof4": "Local Favorite", "socialProof.proof5": "Fast Delivery", "socialProof.proof6": "Quality Guaranteed", "contact.text":
"Ready to enjoy delicious food? Call us now at 0655 311 355 or order online through WhatsApp. We're open 24 hours every day!", "contact.callButton": "📞 Call: 0655 311 355", "contact.whatsappButton": "💬 WhatsApp Order", "faq.sideTitle": "Frequently Asked Questions", "faq.sideDescription":
"Everything you need to know about Kzone Cafe & Grill services, hours, and ordering.", "faq.question1Title": "What are your operating hours?", "faq.question1Content":
"We are open 24 hours every day! Whether you want breakfast, lunch, dinner, or a late-night snack, we're here for you.", "faq.question2Title": "Do you offer delivery?", "faq.question2Content":
"Yes! We offer fast, reliable delivery. Call us at 0655 311 355 or order through WhatsApp. Delivery is available throughout Kigamboni and surrounding areas.", "faq.question3Title": "What is your drive-through process?", "faq.question3Content":
"Simply drive to our location in Mnadani, Kigamboni. You can order from your car and we'll prepare your food quickly for no-contact pickup.", "faq.question4Title": "Can I make reservations?", "faq.question4Content":
"Yes! For group bookings or reservations, please call us at 0655 311 355. We're happy to accommodate your dining needs.", "faq.question5Title": "What payment methods do you accept?", "faq.question5Content":
"We accept cash and mobile money payments (M-Pesa, Airtel Money). Contact us for payment details or online ordering options.", "faq.question6Title": "Are there dietary options?", "faq.question6Content":
"Yes! We offer various menu options including grilled items, vegetarian sides, and fresh drinks. Contact us to discuss specific dietary requirements.", "footer.locationTitle": "Location", "footer.locationAddress": "Mnadani, Kigamboni, Dar es Salaam", "footer.locationMap": "View on Google Maps", "footer.contactTitle": "Contact", "footer.contactPhone": "Phone: 0655 311 355", "footer.contactWhatsapp": "WhatsApp Order", "footer.contactHours": "Hours: Open 24/7", "footer.servicesTitle": "Services", "footer.servicesDineIn": "Dine-In", "footer.servicesDriveThrough": "Drive-Through", "footer.servicesDelivery": "Delivery", "footer.servicesReservations": "Reservations", "footer.copyright":
"© 2025 Kzone Cafe & Grill. All rights reserved. Serving Kigamboni with Fresh Food 24/7."},
sw: {
"nav.home": "Nyumbani", "nav.menu": "Menyu", "nav.services": "Huduma", "nav.contact": "Wasiliana", "nav.about": "Kuhusu", "brand.name": "Kzone Cafe & Grill", "brand.location": "Mnadani, Kigamboni", "brand.phone": "0655 311 355", "hero.logo": "KZONE", "hero.description":
"Chakula Safi, Wakati Wowote Open 24 Saa katika Kigamboni. Kula Ndani, Drive-through, au Uhamiaji. Umerejebishwa 4.7★ na Wajibu 38 wa Wateja.", "hero.callButton": "📞 Piga Simu", "hero.orderButton": "🍽 Agiza Chakula", "hero.slide1Alt": "Kuku Aliyekamatia Moto - Kzone Cafe", "hero.slide2Alt": "Ndani ya Restarani - Kzone Cafe", "hero.slide3Alt": "Burger & Chips - Kzone Cafe", "services.tag": "Huduma", "services.title": "Jinsi Tunavyokusambaza", "services.description":
"Kzone Cafe & Grill inatoa njia nyingi rahisi za kusambaza chakula chetu safi na huduma nzuri.", "services.feature1Title": "Huba ya Kula Ndani", "services.feature1Tag1": "Vikiti Kinzani", "services.feature1Tag2": "Wazimu wa Kirafiki", "services.feature1Alt": "Huba ya Kula Ndani ya Restarani", "services.feature2Title": "Huduma ya Drive-Through", "services.feature2Tag1": "Huduma ya Haraka", "services.feature2Tag2": "Hapana Kuwasiliana", "services.feature2Alt": "Huduma ya Drive-Through", "services.feature3Title": "Uhamiaji wa Haraka", "services.feature3Tag1": "Siku Moja", "services.feature3Tag2": "Kutegemewa", "services.feature3Alt": "Huduma ya Uhamiaji wa Haraka", "testimonials.tag": "Mapitio", "testimonials.title": "Inayopendewa na Jamii ya Kigamboni", "testimonials.description":
"Angalia nini wajibu wangu wanasema kuhusu Kzone Cafe & Grill.", "testimonials.testimonial1Name": "Fatima Hassan", "testimonials.testimonial1Role": "Mkazi wa Ndani", "testimonials.testimonial1Text":
"Sehemu nzuri ya kutulia na familia. Chakula chao kina ladha nzuri sana na huduma ni nzuri.", "testimonials.testimonial1Alt": "Fatima Hassan Muhtasari", "testimonials.testimonial2Name": "James Mwangi", "testimonials.testimonial2Role": "Mwenye Biashara", "testimonials.testimonial2Text":
"Restarani bora ya kuku Kigamboni. Huduma ya haraka, bei nzuri, na ubora wa hali ya juu. Ninatusumbua sana!", "testimonials.testimonial2Alt": "James Mwangi Muhtasari", "testimonials.testimonial3Name": "Amina Mohammed", "testimonials.testimonial3Role": "Mteja Mwenyewe", "testimonials.testimonial3Text":
"Fungua 24 saa ni rafiki kwa akaunti yangu ya usiku. Chakula kila wakati kina upya na wazimu wote ni rafiki.", "testimonials.testimonial3Alt": "Amina Mohammed Muhtasari", "testimonials.testimonial4Name": "David Kipchoge", "testimonials.testimonial4Role": "Mwanafunzi", "testimonials.testimonial4Text":
"Mahali bora pa kuburudika na warafiki. Chakula kizuri, bei nzuri, na weledi wa ajabu. Kupenda!", "testimonials.testimonial4Alt": "David Kipchoge Muhtasari", "testimonials.testimonial5Name": "Sarah Mwangi", "testimonials.testimonial5Role": "Mtendaji wa Kazi", "testimonials.testimonial5Text":
"Huduma rahisi ya drive-through inanisimama wakati. Uhamiaji ni haraka na ubora wa chakula ni sawa kila wakati.", "testimonials.testimonial5Alt": "Sarah Mwangi Muhtasari", "testimonials.testimonial6Name": "Peter Ochieng", "testimonials.testimonial6Role": "Baba wa Familia", "testimonials.testimonial6Text":
"Mpenzi wa Familia! Watoto wanapenda chips na kuku, wazazi wanapenda thamani ya pesa. Rafiki kwa ajili ya familia.", "testimonials.testimonial6Alt": "Peter Ochieng Muhtasari", "menu.tag": "Menyu Maajabu", "menu.title": "Chakula Kilichotengenezwa", "menu.description":
"Onja vipengele vyetu vya menyu vya maajabu - safi, kitamu, na bei nzuri. Angalia menyu kamili kwa chaguo zaidi.", "menu.product1Name": "Kuku Iliyokamatia Moto", "menu.product1Price": "Kuanzia 8,000 TZS", "menu.product1Alt": "Kuku Iliyokamatia Moto", "menu.product2Name": "Burger Nzuri Sana", "menu.product2Price": "Kuanzia 6,000 TZS", "menu.product2Alt": "Burger Nzuri Sana", "menu.product3Name": "Chips Safi", "menu.product3Price": "Kuanzia 3,000 TZS", "menu.product3Alt": "Chips Safi", "menu.product4Name": "Vinywaji Baridi", "menu.product4Price": "Kuanzia 2,000 TZS", "menu.product4Alt": "Vinywaji Baridi", "menu.viewFullMenuButton": "Angalia Menyu Kamili", "whyUs.tag": "Kwa Nini Kuchagua Sisi", "whyUs.title":
"Kzone Cafe & Grill: Restarani Yako ya Karibuni Inayopendekezwa. Open 24 Saa na Huduma ya Haraka, Bei Rahisi, Mazazi Yanayokamatia, na Uaminifu wa Jamii.", "whyUs.reserveButton": "Kamatia Meza", "whyUs.orderButton": "Agiza Sasa", "socialProof.title": "Inaaminiwa na Jamii ya Kigamboni", "socialProof.description":
"Jiunge na maelfu ya wajibu wanaopendelea Kzone Cafe & Grill kila siku.", "socialProof.tag": "Uaminifu wa Jamii", "socialProof.proof1": "Mapitio ya Google: 4.7★", "socialProof.proof2": "38+ Mapitio ya Mteja", "socialProof.proof3": "Huduma 24/7", "socialProof.proof4": "Mpenzi wa Ndani", "socialProof.proof5": "Uhamiaji wa Haraka", "socialProof.proof6": "Ubora Unategemewa", "contact.text":
"Tayari kuburudika na chakula kitamu? Pigia simu sasa katika 0655 311 355 au agiza online kupitia WhatsApp. Tunafungua 24 saa kila siku!", "contact.callButton": "📞 Piga Simu: 0655 311 355", "contact.whatsappButton": "💬 Agiza kupitia WhatsApp", "faq.sideTitle": "Swali Linalojirudia", "faq.sideDescription":
"Kila kitu unachohitaji kujua kuhusu huduma za Kzone Cafe & Grill, saa, na kuagiza.", "faq.question1Title": "Ni saa ngapi unafunguka?", "faq.question1Content":
"Tunafunguka 24 saa kila siku! Kama unataka vidakidaki, chakula, kile kidogo, au kile jioni, tuko hapa kwa ajili yako.", "faq.question2Title": "Je, unatoa uhamiaji?", "faq.question2Content":
"Ndiyo! Tunatoa uhamiaji wa haraka na kutegemewa. Pigia simu sisi 0655 311 355 au agiza kupitia WhatsApp. Uhamiaji upo kwa Kigamboni nzima na maeneo yajiranu.", "faq.question3Title": "Nini njia ya drive-through?", "faq.question3Content":
"Endelea tu mahali petu huko Mnadani, Kigamboni. Unaweza kuagiza kutoka gari lako na tutatalii chakula chako haraka kwa ajili ya kamatiano bila kuwasiliana.", "faq.question4Title": "Je, naweza kukamatia?", "faq.question4Content":
"Ndiyo! Kwa maazoano ya kundi au akaunti, tafadhali pigia simu sisi 0655 311 355. Tunapofika sana kuweka akaunti yako na mahitaji yako ya kula.", "faq.question5Title": "Njia gani za kulipwa unakubaliana?", "faq.question5Content":
"Tunakubaliana na pesa na malipaji ya rununu (M-Pesa, Airtel Money). Wasiliana nasi kwa maelezo ya kulipwa au chaguo za kuagiza mtandaoni.", "faq.question6Title": "Je, kuna chaguo kwa ajili ya mlo?", "faq.question6Content":
"Ndiyo! Tunatoa chaguo vya menyu mbalimbali kama vile vipengele vya kuweka moto, upande wa mbegu, na vinywaji safi. Wasiliana nasi kujadili mahitaji yako ya ajili maalum.", "footer.locationTitle": "Mahali Pago", "footer.locationAddress": "Mnadani, Kigamboni, Dar es Salaam", "footer.locationMap": "Angalia kwenye Google Maps", "footer.contactTitle": "Wasiliana", "footer.contactPhone": "Simu: 0655 311 355", "footer.contactWhatsapp": "Agiza WhatsApp", "footer.contactHours": "Saa: Funguka 24/7", "footer.servicesTitle": "Huduma", "footer.servicesDineIn": "Kula Ndani", "footer.servicesDriveThrough": "Drive-Through", "footer.servicesDelivery": "Uhamiaji", "footer.servicesReservations": "Akaunti", "footer.copyright":
"© 2025 Kzone Cafe & Grill. Haki zote zilizohifadhiwa. Ina Kigamboni na Chakula Safi 24/7."},
};
export const useTranslation = () => {
const [language, setLanguage] = useState<"en" | "sw">("en");
useEffect(() => {
const preferredLanguage = localStorage.getItem("preferredLanguage") as
| "en"
| "sw"
| null;
if (preferredLanguage && translations[preferredLanguage]) {
setLanguage(preferredLanguage);
}
}, []);
const t = (key: string, defaultValue?: string): string => {
const keys = key.split(".");
let value: any = translations[language];
for (const k of keys) {
if (value && typeof value === "object" && k in value) {
value = value[k];
} else {
return defaultValue || key;
}
}
return typeof value === "string" ? value : defaultValue || key;
};
return { t, language, setLanguage };
};

View File

@@ -0,0 +1,63 @@
"use client";
import React, { createContext, useContext, useState, useEffect } from "react";
import { translations } from "./translations";
export type Language = "en" | "sw";
interface LanguageContextType {
language: Language;
setLanguage: (language: Language) => void;
t: (key: string) => string;
}
const LanguageContext = createContext<LanguageContextType | undefined>(
undefined
);
export function LanguageProvider({
children,
}: {
children: React.ReactNode;
}) {
const [language, setLanguageState] = useState<Language>("en");
const [mounted, setMounted] = useState(false);
useEffect(() => {
setMounted(true);
const saved = localStorage.getItem("preferredLanguage") as Language;
if (saved && (saved === "en" || saved === "sw")) {
setLanguageState(saved);
}
}, []);
const setLanguage = (lang: Language) => {
setLanguageState(lang);
localStorage.setItem("preferredLanguage", lang);
};
const t = (key: string): string => {
const keys = key.split(".");
let value: any = translations[language];
for (const k of keys) {
value = value?.[k];
}
return typeof value === "string" ? value : key;
};
if (!mounted) return <>{children}</>;
return (
<LanguageContext.Provider value={{ language, setLanguage, t }}>
{children}
</LanguageContext.Provider>
);
}
export function useLanguage(): LanguageContextType {
const context = useContext(LanguageContext);
if (!context) {
throw new Error("useLanguage must be used within LanguageProvider");
}
return context;
}

View File

@@ -0,0 +1,78 @@
export const translations = {
en: {
nav: {
home: "Home", menu: "Menu", services: "Services", contact: "Contact", about: "About", language: "🇬🇧 English"},
hero: {
description:
"Fresh Food, Anytime Open 24 Hours in Kigamboni. Dine-in, Drive-through, or Delivery. Rated 4.7★ with 38 Customer Reviews.", callNow: "📞 Call Now", orderFood: "🍽 Order Food"},
services: {
tag: "Services", title: "How We Serve You", description:
"Kzone Cafe & Grill offers multiple convenient ways to enjoy our fresh food and excellent service.", dineIn: "Dine-In Experience", dineInTags: ["Comfortable Seating", "Friendly Staff"],
driveThrough: "Drive-Through Service", driveThroughTags: ["Quick Service", "No Contact"],
fastDelivery: "Fast Delivery", fastDeliveryTags: ["Same Day", "Reliable"],
},
testimonials: {
tag: "Reviews", title: "Loved by Kigamboni Community", description: "See what our satisfied customers have to say about Kzone Cafe & Grill."},
menu: {
tag: "Popular Menu", title: "Featured Foods", description:
"Taste our most popular menu items - fresh, delicious, and affordable. View the full menu for more options.", viewFullMenu: "View Full Menu", grilledChicken: "Grilled Chicken", grilledChickenPrice: "From 8,000 TZS", juicyBurger: "Juicy Burger", juicyBurgerPrice: "From 6,000 TZS", freshChips: "Fresh Chips", freshChipsPrice: "From 3,000 TZS", coolDrinks: "Cool Drinks", coolDrinksPrice: "From 2,000 TZS"},
whyUs: {
tag: "Why Choose Us", title:
"Kzone Cafe & Grill: Your Favorite Local Restaurant. Open 24 Hours with Quick Service, Affordable Prices, Friendly Environment, and Community Trust.", reserveTable: "Reserve a Table", orderNow: "Order Now"},
socialProof: {
title: "Trusted by Kigamboni Community", description: "Join thousands of satisfied customers who choose Kzone Cafe & Grill daily.", tag: "Community Trust", proof: [
"Google Reviews: 4.7★", "38+ Customer Reviews", "24/7 Service", "Local Favorite", "Fast Delivery", "Quality Guaranteed"],
},
contact: {
text: "Ready to enjoy delicious food? Call us now at 0655 311 355 or order online through WhatsApp. We're open 24 hours every day!", callButton: "📞 Call: 0655 311 355", whatsappButton: "💬 WhatsApp Order"},
faq: {
title: "Frequently Asked Questions", description:
"Everything you need to know about Kzone Cafe & Grill services, hours, and ordering.", question1: "What are your operating hours?", answer1:
"We are open 24 hours every day! Whether you want breakfast, lunch, dinner, or a late-night snack, we're here for you.", question2: "Do you offer delivery?", answer2:
"Yes! We offer fast, reliable delivery. Call us at 0655 311 355 or order through WhatsApp. Delivery is available throughout Kigamboni and surrounding areas.", question3: "What is your drive-through process?", answer3:
"Simply drive to our location in Mnadani, Kigamboni. You can order from your car and we'll prepare your food quickly for no-contact pickup.", question4: "Can I make reservations?", answer4:
"Yes! For group bookings or reservations, please call us at 0655 311 355. We're happy to accommodate your dining needs.", question5: "What payment methods do you accept?", answer5:
"We accept cash and mobile money payments (M-Pesa, Airtel Money). Contact us for payment details or online ordering options.", question6: "Are there dietary options?", answer6:
"Yes! We offer various menu options including grilled items, vegetarian sides, and fresh drinks. Contact us to discuss specific dietary requirements."},
footer: {
location: "Location", contact: "Contact", services: "Services", mnadani: "Mnadani, Kigamboni, Dar es Salaam", viewMaps: "View on Google Maps", phone: "Phone: 0655 311 355", whatsapp: "WhatsApp Order", hours: "Hours: Open 24/7", dineIn: "Dine-In", driveThrough: "Drive-Through", delivery: "Delivery", reservations: "Reservations", copyright: "© 2025 Kzone Cafe & Grill. All rights reserved. Serving Kigamboni with Fresh Food 24/7."},
},
sw: {
nav: {
home: "Nyumbani", menu: "Menyu", services: "Huduma", contact: "Wasiliana", about: "Kuhusu", language: "🇹🇿 Kiswahili"},
hero: {
description:
"Chakula Safi, Kila Wakati Funguka 24 Saa katika Kigamboni. Kula ndani, Kupitia kwa haraka, au Uhamiaji. Kadiria 4.7★ na Ukaguzi 38 wa Wateja.", callNow: "📞 Piga Simu", orderFood: "🍽 Agiza Chakula"},
services: {
tag: "Huduma", title: "Jinsi Tunavyokuhidimia", description:
"Kzone Cafe & Grill inatoa njia nyingi za kumfanya chakula chetu safi na huduma nzuri.", dineIn: "Uzoefu wa Kula ndani", dineInTags: ["Kiti Kinzuri", "Wafanyakazi Wazimu"],
driveThrough: "Huduma ya Kupitia Haraka", driveThroughTags: ["Huduma ya Haraka", "Bila Mgogoro"],
fastDelivery: "Uhamiaji wa Haraka", fastDeliveryTags: ["Siku Moja", "Amanina"],
},
testimonials: {
tag: "Maoni", title: "Inayopendeeza Jamii ya Kigamboni", description: "Angalia jinsi wateja wangu wanajifanyia kuhusu Kzone Cafe & Grill."},
menu: {
tag: "Menyu Maadhimisho", title: "Chakula Kinachotegemeana", description:
"Jini yetu zaidi ya chakula kinachohitajika zaidi - safi, kinachofanya mwenyewe, na bei rahisi. Angalia menyu kamili kwa ajili ya chaguzi zaidi.", viewFullMenu: "Tazama Menyu Kamili", grilledChicken: "Kuku Aliyekamatia", grilledChickenPrice: "Kuanzia 8,000 TZS", juicyBurger: "Burger Juicy", juicyBurgerPrice: "Kuanzia 6,000 TZS", freshChips: "Chips Safi", freshChipsPrice: "Kuanzia 3,000 TZS", coolDrinks: "Kinywaji Baridi", coolDrinksPrice: "Kuanzia 2,000 TZS"},
whyUs: {
tag: "Kwa Nini Chagua Sisi", title:
"Kzone Cafe & Grill: Mgahawa Wako Mpenzi wa Ndani. Funguka 24 Saa na Huduma ya Haraka, Bei Nzuri, Mazingira Mazuri, na Imani ya Jamii.", reserveTable: "Hifadhi Meza", orderNow: "Agiza Sasa"},
socialProof: {
title: "Inaaminika na Jamii ya Kigamboni", description: "Jiunge na maelfu ya wateja wanajifanyia ambao wanachagua Kzone Cafe & Grill kila siku.", tag: "Imani ya Jamii", proof: [
"Google Reviews: 4.7★", "Ukaguzi 38+ wa Wateja", "Huduma ya 24/7", "Pendeza Inayofaa", "Uhamiaji wa Haraka", "Ubora Unaothibitishwa"],
},
contact: {
text: "Uko tayari kufika chakula kinachotaka? Piga simu sasa katika 0655 311 355 au agiza online kupitia WhatsApp. Tunakulinda 24 saa kila siku!", callButton: "📞 Piga Simu: 0655 311 355", whatsappButton: "💬 Agiza WhatsApp"},
faq: {
title: "Maswali Yanayoulizwa Mara Kwa Mara", description:
"Kila kitu unachohitaji kujua kuhusu huduma za Kzone Cafe & Grill, saa, na agizo.", question1: "Je! Ni nini wakati wa kufungua?", answer1:
"Tunakulinda 24 saa kila siku! Unakutaka kachumbari, mchana, jioni, au likizo nyingi za usiku, nipo hapa kwa ajili yako.", question2: "Je! Unabobea uhamiaji?", answer2:
"Ndio! Tunatoa haraka, uhamiaji amanina. Piga simu 0655 311 355 au agiza kupitia WhatsApp. Uhamiaji upo kwa Kigamboni na maeneo yajifanyia.", question3: "Je! Kwa nini kwa njia ya kupitia haraka?", answer3:
"Kwenda tu mahali petu katika Mnadani, Kigamboni. Unaweza kuagiza kutoka kwa gari lako na tutajifanya chakula chako haraka kwa vile si mgogoro.", question4: "Je! Naweza kuagiza meza?", answer4:
"Ndio! Kwa ajili ya makundi au agizo, tafadhali piga simu 0655 311 355. Tunajifanyia kukidza mahitaji yako ya kula.", question5: "Je! Ni njia gani za kutuma unakubali?", answer5:
"Tunakubali pesa na simu yenye pesa (M-Pesa, Airtel Money). Wasiliana nasi kwa ajili ya maelezo ya kutuma au chaguzi za agizo online.", question6: "Je! Kuna chaguzi za kumla?", answer6:
"Ndio! Tunatoa chaguzi nyingi za menyu kama vile vitu vilivyokamatia, pande zisizo na kuku, na kinywaji safi. Wasiliana nasi kujifanya mahitaji makamata."},
footer: {
location: "Mahali", contact: "Wasiliana", services: "Huduma", mnadani: "Mnadani, Kigamboni, Dar es Salaam", viewMaps: "Angalia kwenye Google Maps", phone: "Simu: 0655 311 355", whatsapp: "Agiza WhatsApp", hours: "Saa: Funguka 24/7", dineIn: "Kula ndani", driveThrough: "Kupitia haraka", delivery: "Uhamiaji", reservations: "Agizo", copyright: "© 2025 Kzone Cafe & Grill. Haki zote zimehifadhiwa. Hudimia Kigamboni na Chakula Safi 24/7."},
},
};

View File

@@ -0,0 +1,56 @@
"use client";
import React, { createContext, useContext, useState, useEffect } from "react";
type Language = "en" | "sw";
interface LanguageContextType {
language: Language;
setLanguage: (lang: Language) => void;
}
const LanguageContext = createContext<LanguageContextType | undefined>(
undefined
);
export function LanguageProvider({
children,
}: {
children: React.ReactNode;
}) {
const [language, setLanguageState] = useState<Language>("en");
const [mounted, setMounted] = useState(false);
useEffect(() => {
setMounted(true);
const savedLanguage =
(localStorage.getItem("preferredLanguage") as Language) || "en";
setLanguageState(savedLanguage);
}, []);
const setLanguage = (lang: Language) => {
setLanguageState(lang);
localStorage.setItem("preferredLanguage", lang);
window.dispatchEvent(
new CustomEvent("languageChange", { detail: { language: lang } })
);
};
if (!mounted) {
return <>{children}</>;
}
return (
<LanguageContext.Provider value={{ language, setLanguage }}>
{children}
</LanguageContext.Provider>
);
}
export function useLanguage() {
const context = useContext(LanguageContext);
if (context === undefined) {
throw new Error("useLanguage must be used within a LanguageProvider");
}
return context;
}

View File

@@ -0,0 +1,11 @@
"use client";
import { LanguageProvider } from "./language-context";
export function ServiceWrapper({
children,
}: {
children: React.ReactNode;
}) {
return <LanguageProvider>{children}</LanguageProvider>;
}