Add new properties to event theme schemas and types
Some checks failed
Build and Push Docker Images / changes (push) Successful in 4s
Build and Push Docker Images / build-backend (push) Has been skipped
Build and Push Docker Images / build-frontend (push) Failing after 48s

Introduce `background_image_url`, `foreground_image_url`, `asset_image_urls`, and `is_active` properties to the `EventTheme` schemas and types. These additions enhance flexibility and allow better customization of event themes. Default value for `is_active` ensures consistent behavior.
This commit is contained in:
2025-03-12 16:23:00 +01:00
parent 288e09202d
commit 9c7bc1f2cf
2 changed files with 141 additions and 0 deletions

View File

@@ -553,6 +553,28 @@ export const EventThemeCreateSchema = {
],
title: "Preview Image Url",
},
background_image_url: {
anyOf: [
{
type: "string",
},
{
type: "null",
},
],
title: "Background Image Url",
},
foreground_image_url: {
anyOf: [
{
type: "string",
},
{
type: "null",
},
],
title: "Foreground Image Url",
},
color_palette: {
additionalProperties: {
type: "string",
@@ -561,6 +583,20 @@ export const EventThemeCreateSchema = {
minProperties: 1,
title: "Color Palette",
},
asset_image_urls: {
anyOf: [
{
additionalProperties: {
type: "string",
},
type: "object",
},
{
type: "null",
},
],
title: "Asset Image Urls",
},
fonts: {
additionalProperties: {
type: "string",
@@ -569,6 +605,11 @@ export const EventThemeCreateSchema = {
minProperties: 1,
title: "Fonts",
},
is_active: {
type: "boolean",
title: "Is Active",
default: true,
},
},
type: "object",
required: ["name", "color_palette", "fonts"],
@@ -604,6 +645,28 @@ export const EventThemeResponseSchema = {
],
title: "Preview Image Url",
},
background_image_url: {
anyOf: [
{
type: "string",
},
{
type: "null",
},
],
title: "Background Image Url",
},
foreground_image_url: {
anyOf: [
{
type: "string",
},
{
type: "null",
},
],
title: "Foreground Image Url",
},
color_palette: {
additionalProperties: {
type: "string",
@@ -612,6 +675,20 @@ export const EventThemeResponseSchema = {
minProperties: 1,
title: "Color Palette",
},
asset_image_urls: {
anyOf: [
{
additionalProperties: {
type: "string",
},
type: "object",
},
{
type: "null",
},
],
title: "Asset Image Urls",
},
fonts: {
additionalProperties: {
type: "string",
@@ -620,6 +697,11 @@ export const EventThemeResponseSchema = {
minProperties: 1,
title: "Fonts",
},
is_active: {
type: "boolean",
title: "Is Active",
default: true,
},
id: {
type: "string",
format: "uuid",
@@ -666,6 +748,28 @@ export const EventThemeUpdateSchema = {
],
title: "Preview Image Url",
},
background_image_url: {
anyOf: [
{
type: "string",
},
{
type: "null",
},
],
title: "Background Image Url",
},
foreground_image_url: {
anyOf: [
{
type: "string",
},
{
type: "null",
},
],
title: "Foreground Image Url",
},
color_palette: {
anyOf: [
{
@@ -680,6 +784,20 @@ export const EventThemeUpdateSchema = {
],
title: "Color Palette",
},
asset_image_urls: {
anyOf: [
{
additionalProperties: {
type: "string",
},
type: "object",
},
{
type: "null",
},
],
title: "Asset Image Urls",
},
fonts: {
anyOf: [
{
@@ -694,6 +812,11 @@ export const EventThemeUpdateSchema = {
],
title: "Fonts",
},
is_active: {
type: "boolean",
title: "Is Active",
default: true,
},
},
type: "object",
title: "EventThemeUpdate",

View File

@@ -82,24 +82,36 @@ export type EventThemeCreate = {
name: string;
description?: string | null;
preview_image_url?: string | null;
background_image_url?: string | null;
foreground_image_url?: string | null;
color_palette: {
[key: string]: string;
};
asset_image_urls?: {
[key: string]: string;
} | null;
fonts: {
[key: string]: string;
};
is_active?: boolean;
};
export type EventThemeResponse = {
name: string;
description?: string | null;
preview_image_url?: string | null;
background_image_url?: string | null;
foreground_image_url?: string | null;
color_palette: {
[key: string]: string;
};
asset_image_urls?: {
[key: string]: string;
} | null;
fonts: {
[key: string]: string;
};
is_active?: boolean;
id: string;
};
@@ -107,12 +119,18 @@ export type EventThemeUpdate = {
name?: string | null;
description?: string | null;
preview_image_url?: string | null;
background_image_url?: string | null;
foreground_image_url?: string | null;
color_palette?: {
[key: string]: string;
} | null;
asset_image_urls?: {
[key: string]: string;
} | null;
fonts?: {
[key: string]: string;
} | null;
is_active?: boolean;
};
export type EventUpdate = {