Brand native Electron menu as Agent Orchestrator#2508
Open
areycruzer wants to merge 2 commits into
Open
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
This PR replaces Electron’s default native menu with an app-owned, branded “Agent Orchestrator” menu template (preserving standard native roles/shortcuts), and adds a macOS dev-only Electron Forge start plugin to ensure the macOS menu bar app label shows “Agent Orchestrator” (instead of “Electron”) during electron-forge start.
Changes:
- Add a main-process helper to build/install a branded native application menu template (with dev-only View menu items like Reload/DevTools).
- Install the native application menu during
app.whenReady()before window creation. - Add a macOS dev-only Forge
startLogichook to prepare a branded Electron executable alias (plus unit tests for both menu and branding paths).
Reviewed changes
Copilot reviewed 6 out of 6 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
| frontend/src/main/dev-electron-branding.ts | Adds macOS dev-bundle branding helpers (Info.plist rewrite + branded executable alias). |
| frontend/src/main/dev-electron-branding.test.ts | Unit tests for dev Electron branding + alias resolution behavior. |
| frontend/src/main/app-menu.ts | Defines branded native menu template + install helper. |
| frontend/src/main/app-menu.test.ts | Unit tests asserting branded macOS app menu and dev-only roles. |
| frontend/src/main.ts | Installs the branded application menu during app startup. |
| frontend/forge.config.ts | Adds a Forge start plugin to use the branded dev Electron executable on macOS. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Closes #2507.
This replaces Electron's default native menu with an app-owned
Agent Orchestratormenu template and preserves the standard native menu roles/shortcuts.The macOS dev path needed one extra piece beyond the menu template:
electron-forge startlaunches the stockElectron.appbinary directly, so macOS still labels the first menu item from the executable path. This PR adds a tiny Forge start plugin that, on macOS dev runs only, creates/uses a branded executable alias inside the local Electron dev bundle so the system menu bar showsAgent Orchestratorduringnpm run devtoo. Packaged builds continue to use the existing Forge packager config.What changed
Agent OrchestratorAgent Orchestratorapp.whenReady()beforecreateWindow().electron-forge startno longer leaves the native app menu branded asElectron.Local verification
npm --prefix frontend test -- app-menu.test.ts dev-electron-branding.test.ts-> 2 files / 11 tests passednpm --prefix frontend run typecheck-> passednpm --prefix frontend test-> 50 files / 483 tests passednpx --yes prettier@3 --check --ignore-unknown frontend/src/main/app-menu.ts frontend/src/main/app-menu.test.ts frontend/src/main/dev-electron-branding.ts frontend/src/main/dev-electron-branding.test.ts frontend/src/main.ts frontend/forge.config.ts-> passedManual macOS smoke with isolated daemon state:
npm --prefix frontend run devwith/tmp/ao-menu-2507-thirdAO state..../Electron.app/Contents/MacOS/Agent Orchestrator .Agent Orchestrator :: AppleAgent OrchestratorFileEditViewWindowHelp/tmp/ao-menu-2507-third/evidence/menu-bar-agent-orchestrator.png