Add third banner image to content upload pipeline

This commit is contained in:
adilallo
2025-09-30 10:24:43 -06:00
parent e47e955c7d
commit febf04b059
5 changed files with 35 additions and 5 deletions
+14 -1
View File
@@ -54,6 +54,17 @@ export const BLOG_POST_SCHEMA = {
},
},
},
banner: {
type: "object",
required: false,
default: null,
properties: {
horizontal: {
type: "string",
required: false,
},
},
},
background: {
type: "object",
required: false,
@@ -162,7 +173,9 @@ export function sanitizeBlogPost(frontmatter) {
if (frontmatter[field] !== undefined) {
// Special handling for thumbnail and background objects
if (
(field === "thumbnail" || field === "background") &&
(field === "thumbnail" ||
field === "background" ||
field === "banner") &&
typeof frontmatter[field] === "object"
) {
sanitized[field] = frontmatter[field];