[v3.8.50] feat(electron): add Remote Server Mode to attach to an external OmniRoute instance (#8799)

Validated in local merge-train T7 (ungrouped batch 2)
This commit is contained in:
Dave
2026-08-06 04:05:24 -05:00
committed by GitHub
parent 4a6871381f
commit 7feafd52c9
12 changed files with 747 additions and 13 deletions

View File

@@ -0,0 +1,15 @@
/**
* Preload for the small "Connect to Remote Server" prompt window.
*
* Kept separate from the main preload.js — this window only ever loads our
* own bundled remoteServerPrompt.html (never remote/untrusted content), but we
* still keep contextIsolation on and expose the minimum surface needed.
*/
const { contextBridge, ipcRenderer } = require("electron");
contextBridge.exposeInMainWorld("remoteServerPrompt", {
getInitialUrl: () => ipcRenderer.invoke("remote-server-prompt:get-initial-url"),
submit: (url) => ipcRenderer.send("remote-server-prompt:submit", url),
cancel: () => ipcRenderer.send("remote-server-prompt:cancel"),
});