From 62e2e2987940df002c5d5bc402565a4cd59e1259 Mon Sep 17 00:00:00 2001 From: Ksan Date: Wed, 2 Sep 2026 13:21:25 +0200 Subject: [PATCH] Add FAQ section and footer phone contact picker --- app/[locale]/about/AboutContent.tsx | 84 ++++++++++++++++++++++++++- components/layout/Footer.tsx | 10 +++- components/layout/FooterPhoneLink.tsx | 34 +++++++++++ lib/dictionaries.ts | 76 ++++++++++++++++++++++++ 4 files changed, 201 insertions(+), 3 deletions(-) create mode 100644 components/layout/FooterPhoneLink.tsx diff --git a/app/[locale]/about/AboutContent.tsx b/app/[locale]/about/AboutContent.tsx index 1e147cb..f6d5baf 100644 --- a/app/[locale]/about/AboutContent.tsx +++ b/app/[locale]/about/AboutContent.tsx @@ -1,7 +1,8 @@ "use client"; import Link from "next/link"; -import { motion } from "framer-motion"; +import { useState } from "react"; +import { AnimatePresence, motion } from "framer-motion"; import { GitBranch, Lock, @@ -12,6 +13,7 @@ import { Globe, Briefcase, Clock, + Plus, } from "lucide-react"; import GlassCard from "@/components/ui/GlassCard"; import { fadeUp, stagger, viewportConfig } from "@/lib/animations"; @@ -42,6 +44,7 @@ type ApproachParagraph = TextParagraph | LinkParagraph; export default function AboutContent({ locale, dict }: AboutContentProps) { const t = dict.aboutPage; + const [openFaq, setOpenFaq] = useState(null); return ( <> @@ -152,6 +155,85 @@ export default function AboutContent({ locale, dict }: AboutContentProps) { + {/* FAQ */} +
+
+ + + {t.faqTitle} + + + + + {t.faq.map((item, i) => { + const isOpen = openFaq === i; + return ( + + +

+ +

+ + + {isOpen && ( + +

+ {item.answer} +

+
+ )} +
+
+
+ ); + })} +
+
+
+ {/* Highlights */}
diff --git a/components/layout/Footer.tsx b/components/layout/Footer.tsx index 62ca848..78299ab 100644 --- a/components/layout/Footer.tsx +++ b/components/layout/Footer.tsx @@ -4,12 +4,15 @@ import { FaLinkedin } from "react-icons/fa6"; import { SiGitea, SiViber, SiWhatsapp } from "react-icons/si"; import type { Locale, Dictionary } from "@/lib/dictionaries"; import { LogoMark } from "@/components/ui/Logo"; +import FooterPhoneLink from "@/components/layout/FooterPhoneLink"; interface FooterProps { locale: Locale; dict: Dictionary; } +const PHONE_NUMBER = "+387 66 644 094"; + export default function Footer({ locale, dict }: FooterProps) { const footerLinks = { [dict.footer.product]: [ @@ -23,7 +26,8 @@ export default function Footer({ locale, dict }: FooterProps) { [dict.footer.connect]: [ { label: "Source Code", href: "https://git.ksan.dev/ksan", external: true }, { label: "Email", href: "mailto:contact@ksan.dev", external: true }, - { label: "+387 66 644 094", href: "tel:+38766644094", external: true }, + // Opens the call / WhatsApp / Viber picker instead of jumping straight to tel:. + { label: PHONE_NUMBER, href: "tel:+38766644094", phone: true }, { label: "LinkedIn", href: "https://www.linkedin.com/in/%C4%91or%C4%91e-k%C5%A1an-886871266", external: true }, ], }; @@ -87,7 +91,9 @@ export default function Footer({ locale, dict }: FooterProps) {