summary refs log tree commit diff
path: root/src/schemas/api/guilds/Role.ts
blob: 2f32e5d7589cb7bb22fab41f819332934d9d9bec (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
export class RoleColors {
    primary_color: number;
    secondary_color: number | undefined; // only used for "holographic" and "gradient" styles
    tertiary_color?: number | undefined; // only used for "holographic" style

    toJSON(): RoleColors {
        return {
            ...this,
            secondary_color: this.secondary_color ?? undefined,
            tertiary_color: this.tertiary_color ?? undefined,
        };
    }
}