generated from nhcarrigan/template
f3c2e8fa40
Adds a two-step new thread modal: step one picks mode, step two configures aspect ratio (Art mode only, six options) and resolution (all modes: 1K/2K/4K). Settings are stored on the thread and forwarded to the Gemini API on every send, retry, and edit. Also regenerates icon.ico with Python to produce a clean all-BMP ICO compatible with both Tauri's proc macro and llvm-rc cross-compilation.
58 lines
1.1 KiB
TypeScript
58 lines
1.1 KiB
TypeScript
/**
|
|
* @file Type definitions for the Tatsumi application.
|
|
* @copyright Naomi Carrigan
|
|
* @license Naomi's Public License
|
|
* @author Naomi Carrigan
|
|
*/
|
|
|
|
type AspectRatio = "1:1" | "3:4" | "4:3" | "9:16" | "16:9" | "21:9";
|
|
type ImageSize = "1K" | "2K" | "4K";
|
|
type Mode = "avatar" | "art" | "replace";
|
|
|
|
interface Config {
|
|
apiKey: string;
|
|
}
|
|
|
|
interface PendingInput {
|
|
imageBase64?: string;
|
|
imageMime?: string;
|
|
imagePreview?: string;
|
|
text?: string;
|
|
}
|
|
|
|
interface MessagePart {
|
|
imageData?: string;
|
|
mimeType?: string;
|
|
text?: string;
|
|
thoughtSignature?: string;
|
|
type: "image" | "text" | "thought";
|
|
}
|
|
|
|
interface ThreadMessage {
|
|
cost?: number;
|
|
parts: Array<MessagePart>;
|
|
role: "user" | "model";
|
|
}
|
|
|
|
interface Thread {
|
|
aspectRatio?: AspectRatio;
|
|
createdAt: number;
|
|
id: string;
|
|
imageSize?: ImageSize;
|
|
messages: Array<ThreadMessage>;
|
|
mode: Mode;
|
|
name: string;
|
|
updatedAt: number;
|
|
}
|
|
|
|
export type {
|
|
AspectRatio,
|
|
Config,
|
|
ImageSize,
|
|
MessagePart,
|
|
Mode,
|
|
PendingInput,
|
|
Thread,
|
|
ThreadMessage,
|
|
};
|