Update content page background

This commit is contained in:
adilallo
2025-09-30 08:43:32 -06:00
parent cc1d2ec7de
commit af4a08b934
7 changed files with 51 additions and 9 deletions
+14 -1
View File
@@ -201,6 +201,16 @@ export default async function BlogPostPage({ params }) {
],
};
// Get article-specific background color from frontmatter
const getBackgroundColor = (post) => {
if (post.frontmatter?.background?.color) {
return post.frontmatter.background.color;
}
return "#1F2937"; // Default fallback (dark gray)
};
const backgroundColor = getBackgroundColor(post);
return (
<>
{/* Structured Data */}
@@ -217,7 +227,10 @@ export default async function BlogPostPage({ params }) {
}}
/>
<div className="min-h-screen bg-[#F4F3F1] relative overflow-hidden">
<div
className="min-h-screen relative overflow-hidden"
style={{ backgroundColor }}
>
{/* Content Banner */}
<ContentBanner post={post} />