project-client/src/main/splash.ts

20 lines
443 B
TypeScript
Raw Normal View History

2023-03-30 08:02:30 +09:00
import { BrowserWindow } from "electron";
import { join } from "path";
import { STATIC_DIR } from "shared/paths";
2023-03-30 08:02:30 +09:00
export function createSplashWindow() {
const splash = new BrowserWindow({
transparent: true,
frame: false,
height: 350,
width: 300,
center: true,
resizable: false,
maximizable: false
});
splash.loadFile(join(STATIC_DIR, "splash.html"));
2023-03-30 08:02:30 +09:00
return splash;
}