feat: render CMS content fields and footer settings
This commit is contained in:
@@ -6,6 +6,7 @@ import { BlockRenderer } from "@/blocks/BlockRenderer";
|
||||
import type { SolutionPageDetail } from "@/types/wagtail";
|
||||
import { createPageMetadata, getPageSEO } from "@/services/seo.service";
|
||||
import PageSEO from "@/components/layout/PageSEO";
|
||||
import { PageCover } from "@/components/layout/PageContent";
|
||||
|
||||
interface SolutionDetailPageProps {
|
||||
params: Promise<{ slug: string }>;
|
||||
@@ -24,7 +25,7 @@ export default async function SolutionDetailPage({
|
||||
const { slug } = await params;
|
||||
const solution = await getPreviewOrFallback<SolutionPageDetail>(
|
||||
"solutions.solutionpage",
|
||||
"body,industry,summary",
|
||||
"body,industry,summary,cover_image",
|
||||
() => getSolutionBySlug(slug).catch(() => null),
|
||||
);
|
||||
|
||||
@@ -39,8 +40,10 @@ export default async function SolutionDetailPage({
|
||||
{solution.title}
|
||||
</h1>
|
||||
{solution.industry && (
|
||||
<p className="mb-12 text-sm text-slate-500">{solution.industry}</p>
|
||||
<p className="mb-4 text-sm text-slate-500">{solution.industry}</p>
|
||||
)}
|
||||
{solution.summary && <p className="mb-6 text-lg text-slate-600">{solution.summary}</p>}
|
||||
<PageCover image={solution.cover_image} />
|
||||
<BlockRenderer blocks={solution.body} />
|
||||
</article>
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user