Repository navigation
Description
Parent
What to build
During an Update download, the main page shows a modal dialog titled Downloading update that follows the live download. It can't be dismissed. When the state returns to idle (the download failed), the dialog closes before the existing error box appears.
Main sends each UpdateDownload state change to the current window's page on a new event channel (skipped when there is no window). The page subscribes through a new rendererBridge subscription onUpdateDownload(listener), following docs/agents/renderer-bridge.md and the existing onEvent pattern: returns an unsubscribe, allows more than one listener, puts id on the payload. The channel name lives in the shared ipc constants; RendererBridge and the global Window typing gain the method. The store keeps the latest state, wired where it starts its other bridge listeners.
A new UpdateDownloadDialog on the main page is open whenever the status is not idle. MUI Dialog, maxWidth="xs", disableEscapeKeyDown, no close button, backdrop click does nothing. Copy (fixed by the prototype in #390):
| State | Bar | Percent text | Status line |
|---|---|---|---|
connecting |
indeterminate LinearProgress |
"Starting…" | "Connecting to the update server…" |
downloading (<100) |
determinate, value=percent |
rounded percent, e.g. "42%" | "RAxML-GUI will quit and install when the download finishes." |
restarted (<100) |
determinate | rounded percent | "Retrying with the full download…" |
percent 100, or done |
determinate at 100 | "100%" | "Download complete. Preparing to install…" |
No bytes anywhere. The page stays free of Node; no second window, renderer entry, or preload.
Acceptance criteria
- Main sends every state change to the window's page on the new channel; the Vitest fake window records the
webContents.sendpayloads (connecting,downloading,restarted,done, andidlebefore the error box) -
onUpdateDownloadexposed onrendererBridge, typed onRendererBridgeandWindow, channel in the shared ipc constants - Preload proof file for
onUpdateDownload(subscribe: true, adownloadingpayload includingid) - Store holds the latest state from the subscription
-
UpdateDownloadDialogrenders the four rows above, ignores Escape and backdrop clicks, has no close button - Page test with
installBridge: pushingconnecting,downloading42,restarted10 anddoneshows the title, percent text and status line for each; pushingidleremoves the dialog - One exposes sentence and one behaviour sentence for
onUpdateDownloadin the preload paragraph ofdocs/research/electron-vite-packaging.md
Activity
Show the Downloading update dialog from live progress events (#395) (#…
jtklein-agents commentedon Nov 27, 2026
Done in #398 (merged into spec/393-update-download-progress). Not done: the two onUpdateDownload sentences for docs/research/electron-vite-packaging.md, because that file is on no branch.
Show update download progress in a dialog and on the Dock/taskbar icon (