Skip to content

Commit

Permalink
Monochromatic themes
Browse files Browse the repository at this point in the history
  • Loading branch information
stefanoverna committed Jan 16, 2024
1 parent f4e6283 commit e530d8d
Show file tree
Hide file tree
Showing 6 changed files with 157 additions and 119 deletions.
116 changes: 64 additions & 52 deletions packages/cma-client/src/generated/SchemaTypes.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10139,35 +10139,31 @@ export type PublicInfoAttributes = {
* Specifies the color-scheme for the project
*/
theme: {
primary_color?: {
primary_color: {
red: number;
green: number;
blue: number;
alpha: number;
[k: string]: unknown;
};
light_color?: {
light_color: {
red: number;
green: number;
blue: number;
alpha: number;
[k: string]: unknown;
};
accent_color?: {
accent_color: {
red: number;
green: number;
blue: number;
alpha: number;
[k: string]: unknown;
};
dark_color?: {
dark_color: {
red: number;
green: number;
blue: number;
alpha: number;
[k: string]: unknown;
};
[k: string]: unknown;
};
/**
* Additional information (only returned on authenticated requests)
Expand Down Expand Up @@ -10508,39 +10504,42 @@ export type SiteAttributes = {
* Specifies the theme to use in administrative area
*/
theme: {
/**
* If type is monochromatic, the hue will determine the color palette. Dark color is a legacy property, and it won't be used on the interface
*/
type: 'custom' | 'monochromatic';
/**
* If the type is monochromatic, the value will fall between 0 and 359. If it's not, the value will be null.
*/
hue: number | null;
primary_color: {
red: number;
green: number;
blue: number;
alpha: number;
[k: string]: unknown;
};
light_color: {
red: number;
green: number;
blue: number;
alpha: number;
[k: string]: unknown;
};
accent_color: {
red: number;
green: number;
blue: number;
alpha: number;
[k: string]: unknown;
};
dark_color: {
red: number;
green: number;
blue: number;
alpha: number;
[k: string]: unknown;
};
/**
* The site logo
* The upload ID that is used as the logo for the project
*/
logo: string | null;
[k: string]: unknown;
};
/**
* Specifies default global settings
Expand Down Expand Up @@ -10705,44 +10704,57 @@ export type SiteUpdateSchema = {
* Site name
*/
name?: string;
/**
* Specifies the theme to use in administrative area
*/
theme?: {
primary_color: {
red: number;
green: number;
blue: number;
alpha: number;
[k: string]: unknown;
};
light_color: {
red: number;
green: number;
blue: number;
alpha: number;
[k: string]: unknown;
};
accent_color: {
red: number;
green: number;
blue: number;
alpha: number;
[k: string]: unknown;
};
dark_color: {
red: number;
green: number;
blue: number;
alpha: number;
[k: string]: unknown;
};
/**
* The site logo
*/
logo: string | null;
[k: string]: unknown;
};
theme?:
| {
/**
* Type of theme color palette
*/
type: 'monochromatic';
/**
* If the type is monochromatic, the value will fall between 0 and 359. If it's not, the value will be null.
*/
hue: number | null;
/**
* The upload ID that is used as the logo for the project
*/
logo: string | null;
[k: string]: unknown;
}
| {
/**
* Type of theme color palette
*/
type?: 'custom';
/**
* The upload ID that is used as the logo for the project
*/
logo: string | null;
primary_color: {
red: number;
green: number;
blue: number;
alpha: number;
};
light_color: {
red: number;
green: number;
blue: number;
alpha: number;
};
accent_color: {
red: number;
green: number;
blue: number;
alpha: number;
};
dark_color?: {
red: number;
green: number;
blue: number;
alpha: number;
};
[k: string]: unknown;
};
/**
* Available locales
*/
Expand Down
Loading

0 comments on commit e530d8d

Please sign in to comment.