feat(electron): add main process, preload, store, protocol, and type definitions

- Add ElectronAPI type definitions and runtime contract (isElectron guard)
- Add electron-store with backend connection data model
- Add centralized API base URL utility (api-base.ts)
- Implement app:// custom protocol with API proxy
- Implement preload script with full contextBridge API
- Complete main process: BrowserWindow config, IPC handlers, window controls
- Register app:// scheme as privileged for secure renderer access
This commit is contained in:
DrSmoothl
2026-03-03 00:52:53 +08:00
parent e6862e227b
commit b5cc361ce9
10 changed files with 843 additions and 67 deletions

View File