interface Update { name: string; data: Message[] | Message | Annotation | string; } interface Message { modifier: string; content: string[]; context: boolean | string; uid: string; } interface Annotation { name: string; data: string | string[]; uid: string; } interface Raw { text: string | boolean; audio: string | boolean; } interface WindowState { width: number; height: number; x: number | null; y: number | null; } interface Profile { crimataId: string; alias: string; initials: string; } interface LoginPayload { email: string; password: string; } interface AuthState { profile: Profile | null; token: string | null; } interface AccountCredentials { email: string; password: string; } /* * Electron Ipc */ interface IpcHandlerCallback { (payload: I | null): Promise; } interface IpcListenerCallback { (payload: T): void; } interface IIpcHandler { handle(): void; remove(): void; readonly _handlerCallback: IpcHandlerCallback; } interface IIpcListener { listen(): void; remove(): void; readonly _listenerCallback: IpcListenerCallback; } interface IPCHandlers { [handler: string]: IIpcHandler; } interface IPCListeners { [listener: string]: IIpcListener | null; } interface IpcRendererEvent { channel: string; payload: T | null; }