Files
SlpSoftware/src/prerender/StaticLanding.tsx
T

43 lines
1.9 KiB
TypeScript

import { Hero } from '../features/landing/components/Hero';
import { AboutSection } from '../features/landing/components/AboutSection';
import { ProcessSection } from '../features/landing/components/ProcessSection';
import { ContactSection } from '../features/landing/components/ContactSection';
import { Footer } from '../components/layout/Footer';
import { t } from '../i18n';
/**
* Static, crawler-readable text of the landing page (NFR-9), rendered to HTML at build time by
* scripts/prerender.mjs and put inside #root of dist/index.html.
*
* Approach: NO hydration. main.tsx uses createRoot, which replaces this markup as soon as the
* app has loaded. That avoids hydration mismatches by construction (the real app reads
* localStorage/matchMedia while rendering; this tree must not). Only components without
* window/storage/query dependencies are used here. Dynamic parts (packages, banner, contact
* form) are NOT prerendered; the packages come from the CMS host markers in index.html. The hero is the baked
* fallback, between the markers <!--CMS:HERO-HTML--> that scripts/prerender.mjs writes: the host replaces the
* region when the CMS has a hero (docs/hero-integration.md).
*/
export function StaticLanding() {
return (
<>
<main id="main">
<Hero regionMarkers />
<AboutSection />
<section id="pakketten" aria-labelledby="pakketten-heading" className="bg-surface">
<div className="mx-auto max-w-[1280px] px-6 pb-24 pt-20 sm:px-8 md:pb-[136px] md:pt-32">
<h2
id="pakketten-heading"
className="max-w-[12ch] text-[clamp(40px,5.4vw,80px)] font-extrabold leading-[0.95] tracking-[-0.03em] [font-stretch:112%]"
>
{t('home.static.packagesHeading')}
</h2>
</div>
</section>
<ProcessSection />
<ContactSection panel={null} />
</main>
<Footer />
</>
);
}