Files
hydra/src/types/theme.types.ts
2025-01-24 15:27:46 -03:00

24 lines
521 B
TypeScript

import { isValidHexColor } from "@main/helpers";
import { z } from "zod";
const hexColorSchema = z.string().refine(isValidHexColor);
type HexColorType = z.infer<typeof hexColorSchema>;
export interface Theme {
id: string;
name: string;
colors: {
accent: HexColorType;
background: HexColorType;
surface: HexColorType;
optional1?: HexColorType;
optional2?: HexColorType;
};
description?: string;
author: number;
isActive: boolean;
code: string;
createdAt: Date;
updatedAt: Date;
}