screenshot-to-code/frontend/src/types.ts
2023-11-30 11:36:39 -05:00

37 lines
763 B
TypeScript

export enum EditorTheme {
ESPRESSO = "espresso",
COBALT = "cobalt",
}
export enum CSSOption {
TAILWIND = "tailwind",
BOOTSTRAP = "bootstrap",
}
export enum JSFrameworkOption {
NO_FRAMEWORK = "vanilla",
REACT = "react",
VUE = "vue",
}
export interface OutputSettings {
css: CSSOption;
js: JSFrameworkOption;
}
export interface Settings {
openAiApiKey: string | null;
openAiBaseURL: string | null;
screenshotOneApiKey: string | null;
isImageGenerationEnabled: boolean;
editorTheme: EditorTheme;
isTermOfServiceAccepted: boolean; // Only relevant for hosted version
accessCode: string | null; // Only relevant for hosted version
}
export enum AppState {
INITIAL = "INITIAL",
CODING = "CODING",
CODE_READY = "CODE_READY",
}