import type { Metadata } from "next"; import { getLocale, getTranslations } from "next-intl/server"; import { Container } from "@/components/layout/container"; import { PageHero } from "@/components/layout/page-hero"; import { MotionFade } from "@/components/motion-fade"; import { AppCard } from "@/components/ui/app-card"; import { Badge } from "@/components/ui/badge"; import { CapabilitiesSection } from "@/components/home/capabilities-section"; import { ProcessSection } from "@/components/home/process-section"; import { ContactCtaSection } from "@/components/home/contact-cta-section"; import type { CapabilitiesSectionCopy, ContactCtaSectionCopy, ProcessSectionCopy, } from "@/components/home/types"; import { getSiteSettings } from "@/lib/app-config"; import { getLocalizedPath, resolveLocale } from "@/lib/locale"; import { buildLocalizedMetadata } from "@/lib/metadata"; type AboutPageProps = { params: Promise<{ locale: string; }>; }; export const dynamic = "force-dynamic"; export async function generateMetadata({ params }: AboutPageProps): Promise { await params; const siteSettings = await getSiteSettings(); const localeKey = resolveLocale(await getLocale().catch(() => siteSettings.defaultLocale), siteSettings.defaultLocale); const t = await getTranslations({ locale: localeKey, namespace: "aboutPage" }); return await buildLocalizedMetadata({ locale: localeKey, pathname: "/about", title: t("title"), description: t("description"), }); } export default async function AboutPage({ params }: AboutPageProps) { await params; const siteSettings = await getSiteSettings(); const localeKey = resolveLocale(await getLocale().catch(() => siteSettings.defaultLocale), siteSettings.defaultLocale); const t = await getTranslations({ locale: localeKey, namespace: "aboutPage" }); const contactHref = getLocalizedPath(localeKey, "/contact", siteSettings.defaultLocale); const capabilitiesCopy: CapabilitiesSectionCopy = { eyebrow: t("capabilities.eyebrow"), title: t("capabilities.title"), description: t("capabilities.description"), items: t.raw("capabilities.items") as CapabilitiesSectionCopy["items"], }; const processCopy: ProcessSectionCopy = { eyebrow: t("process.eyebrow"), title: t("process.title"), description: t("process.description"), steps: t.raw("process.steps") as ProcessSectionCopy["steps"], }; const contactCtaCopy: ContactCtaSectionCopy = { eyebrow: t("contactCta.eyebrow"), title: t("contactCta.title"), description: t("contactCta.description"), contactCta: t("contactCta.contactCta"), githubCta: t("contactCta.githubCta"), emailLabel: t("contactCta.emailLabel"), emailValue: t("contactCta.emailValue"), availabilityLabel: t("contactCta.availabilityLabel"), availabilityValue: t("contactCta.availabilityValue"), githubHref: t("contactCta.githubHref"), }; const storyParagraphs = t.raw("story.paragraphs") as string[]; const toolItems = t.raw("tools.items") as string[]; return ( <>

{t("story.eyebrow")}

{t("story.title")}

{storyParagraphs.map((paragraph) => (

{paragraph}

))}

{t("tools.eyebrow")}

{t("tools.title")}

{toolItems.map((tool) => ( {tool} ))}

{t("personalNote.eyebrow")} {" — "} {t("personalNote.text")}

); }