29 lines
970 B
TypeScript
29 lines
970 B
TypeScript
// electron-env.d.ts
|
|
export interface IElectronAPI {
|
|
setMainWindowSize: (config: any) => void;
|
|
getWindowSize: () => any;
|
|
setViewStatus: (status: 'quit' | 'maximize' | 'minimize' | 'unmaximize' | 'hide') => void;
|
|
getIsMaximized: () => Promise<boolean>;
|
|
setWriteText: (text: string) => void;
|
|
onQuit: (callBack: Function) => void;
|
|
onUpdate: (callBack: Function) => void;
|
|
joinNotification: (data: { name: string, body: string }) => void;
|
|
onDownload: (data: string) => void
|
|
selectFilePath: (data?: any) => void
|
|
onFilePath: (callBack: Function) => void;
|
|
getSources: () => any;
|
|
quit: () => any;
|
|
downFile: (callBack: Function) => void;
|
|
quitAndInstall: (callBack: Function) => void;
|
|
getVersion: () => Promise<string>;
|
|
setRegistry: (uuid: string) => any;
|
|
getRegistry: () => any;
|
|
createChildWindow: (config: any) => void;
|
|
}
|
|
|
|
declare global {
|
|
interface Window {
|
|
electron: IElectronAPI;
|
|
}
|
|
}
|