Builds the markers, data block and stand-in host for the CMS host injection

The pages carry the CMS markers (data block, list regions, JSON-LD price,
inline price); PackagesProvider reads the host's data block after hydration
and asks the API only when there is none; the site address comes from the
block. A stand-in for the host (config/hostInjector.ts, --cms-data in the
preview server) and browser tests check the behaviour with different data.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-11-15 16:21:08 +01:00
co-authored by Claude Sonnet 5.5
parent 16027f5688
commit bf21b6f690
26 changed files with 1207 additions and 70 deletions
+2
View File
@@ -3,6 +3,7 @@ import type { ReactNode } from 'react';
import { createRootRoute, HeadContent, Scripts } from '@tanstack/react-router';
import { ChakraProvider } from '@chakra-ui/react';
import AppShell from '../components/AppShell';
import CmsDataIsland from '../components/CmsRegion/CmsDataIsland';
import PackagesProvider from '../components/PackagesProvider/PackagesProvider';
import NoScriptStyles from '../components/NoScript/NoScriptStyles';
import ErrorPage from '../components/StatusPage/ErrorPage';
@@ -34,6 +35,7 @@ const RootDocument = ({ children }: { children: ReactNode }) => (
<NoScriptStyles />
</head>
<body>
<CmsDataIsland />
{/* De site is alleen licht; de _dark-waarden in het thema blijven
staan voor een eventuele donkere modus later */}
<ChakraProvider value={system}>{children}</ChakraProvider>
+7 -1
View File
@@ -23,7 +23,13 @@ function GezinPage() {
return (
<>
{shootPageGraph(view, siteContent).map((data) => (
<StructuredData key={data['@type']} data={data} />
<StructuredData
key={data['@type']}
data={data}
offerSlug={
data['@type'] === 'WebPage' ? 'gezin' : undefined
}
/>
))}
<ShootPage view={view} />
</>
@@ -23,7 +23,13 @@ function NewbornPage() {
return (
<>
{shootPageGraph(view, siteContent).map((data) => (
<StructuredData key={data['@type']} data={data} />
<StructuredData
key={data['@type']}
data={data}
offerSlug={
data['@type'] === 'WebPage' ? 'newborn' : undefined
}
/>
))}
<ShootPage view={view} />
</>
@@ -23,7 +23,13 @@ function ZwangerschapPage() {
return (
<>
{shootPageGraph(view, siteContent).map((data) => (
<StructuredData key={data['@type']} data={data} />
<StructuredData
key={data['@type']}
data={data}
offerSlug={
data['@type'] === 'WebPage' ? 'zwangerschap' : undefined
}
/>
))}
<ShootPage view={view} />
</>