From af4bd74d67124be22ad0722591b48762bb15eabd Mon Sep 17 00:00:00 2001 From: Vadym Samoilenko Date: Mon, 8 Jun 2026 14:13:31 +0100 Subject: [PATCH] feat(home): add patternGreen/patternOrange CMS upload fields to birthdayIntro Allow editors to upload custom background pattern images for the birthday section cards (green cards and featured orange card) from the CMS admin. Co-Authored-By: Claude Sonnet 4.6 --- src/globals/HomePage.ts | 18 +++++++++++++++++- src/types/globals.ts | 2 ++ 2 files changed, 19 insertions(+), 1 deletion(-) diff --git a/src/globals/HomePage.ts b/src/globals/HomePage.ts index 693289e..807e14e 100644 --- a/src/globals/HomePage.ts +++ b/src/globals/HomePage.ts @@ -185,7 +185,23 @@ export const HomePage: GlobalConfig = { { name: 'birthdayIntro', type: 'group', - fields: [{ name: 'text', type: 'textarea' }], + fields: [ + { name: 'text', type: 'textarea' }, + { + name: 'patternGreen', + type: 'upload', + relationTo: 'media', + label: 'Паттерн зелених карток', + admin: { description: 'Фоновий паттерн для не-featured карток (зелений фон).' }, + }, + { + name: 'patternOrange', + type: 'upload', + relationTo: 'media', + label: 'Паттерн оранжевої картки', + admin: { description: 'Фоновий паттерн для featured картки (оранжевий фон).' }, + }, + ], }, { name: 'news', diff --git a/src/types/globals.ts b/src/types/globals.ts index 609e0c0..7a72ca9 100644 --- a/src/types/globals.ts +++ b/src/types/globals.ts @@ -116,6 +116,8 @@ export interface HomePageVideo { export interface HomePageBirthdayIntro { text?: string | null + patternGreen?: Media | string | null + patternOrange?: Media | string | null } export interface HomePageNews {