Local-first AI coding agent desktop: Electron + Rust host core + pi Agent Harness + user-installable plugins
TypeScript ai-agentcoding-agentdesktop-appelectronglobali18nlocal-firstmcppipi-agentpi-desktoppluginsreactrusttypescript
fix(macos): keep the translucent window surface on by default
vastsa1d6dbd988e70
diff --git a/apps/desktop/electron/main/bootstrap/app-lifecycle.ts b/apps/desktop/electron/main/bootstrap/app-lifecycle.tsindex 2a69066d6..b3f95f99c 100644--- a/apps/desktop/electron/main/bootstrap/app-lifecycle.ts+++ b/apps/desktop/electron/main/bootstrap/app-lifecycle.ts@@ -593,8 +593,10 @@ export function createApplicationLifecycle({function applyMacosWindowTranslucency(settings?: { macosWindowTranslucency?: unknown } | null,) {+ // Absent means the shipped translucency: the setting is an opt-out for the+ // GPU cost of the material, never an opt-in that changes the default look.state.macosWindowTranslucency =- process.platform === "darwin" && settings?.macosWindowTranslucency === true;+ process.platform === "darwin" && settings?.macosWindowTranslucency !== false;}/**diff --git a/apps/desktop/electron/main/bootstrap/main-state.ts b/apps/desktop/electron/main/bootstrap/main-state.tsindex cbcab4dcb..4e602c13d 100644--- a/apps/desktop/electron/main/bootstrap/main-state.ts+++ b/apps/desktop/electron/main/bootstrap/main-state.ts@@ -79,7 +79,12 @@ export class MainProcessState {closePromptOpen = false;quitConfirmed = false;developerMode = false;- macosWindowTranslucency = false;+ /**+ * Translucency is the shipped macOS surface, so a boot that never reads+ * settings (host unavailable) still paints the window the user expects. The+ * preference can only turn it off.+ */+ macosWindowTranslucency = true;updaterLocale = "en";pluginPanelTheme: PluginPanelTheme = nativeTheme.shouldUseDarkColors ? "dark" : "light";diff --git a/apps/desktop/electron/main/bootstrap/window.ts b/apps/desktop/electron/main/bootstrap/window.tsindex 9181c1446..4d833409a 100644--- a/apps/desktop/electron/main/bootstrap/window.ts+++ b/apps/desktop/electron/main/bootstrap/window.ts@@ -257,13 +257,19 @@ export async function createWindow({installWindowShape(window, DEFAULT_WINDOW_CORNER_RADIUS, screen);}}- applyMainWindowBackground(- window,- process.platform,- initialWindowBackground,- windows11NativeCorners,- initialWindowBackground,- );+ // A translucent macOS window owns its transparent backing and the native+ // vibrancy material; painting the host palette here would flatten the glass+ // and quietly make the setting look broken. The opaque surface still takes+ // the colour on every platform.+ if (!(process.platform === "darwin" && windowState.macosWindowTranslucency)) {+ applyMainWindowBackground(+ window,+ process.platform,+ initialWindowBackground,+ windows11NativeCorners,+ initialWindowBackground,+ );+ }suppressLinuxFramelessSystemMenu(window);const initialBounds = window.getBounds();windowState.workPanelBaseBounds = restoredBoundsdiff --git a/apps/desktop/electron/main/ipc/window-ipc.ts b/apps/desktop/electron/main/ipc/window-ipc.tsindex 61bca7a9d..8c1722470 100644--- a/apps/desktop/electron/main/ipc/window-ipc.ts+++ b/apps/desktop/electron/main/ipc/window-ipc.ts@@ -181,9 +181,13 @@ export function registerWindowIpc({) {throw new Error("unsupported window control action");}+ // A window outside macOS has no vibrancy surface: report `false` so the+ // renderer never reads "not applicable" as "translucent".+ const macosWindowTranslucency =+ process.platform === "darwin" && isMacosWindowTranslucent();const mainWindow = getMainWindow();if (!mainWindow || mainWindow.isDestroyed()) {- return { maximized: false, macosWindowTranslucency: isMacosWindowTranslucent() };+ return { maximized: false, macosWindowTranslucency };}switch (input.action as WindowControlAction) {case "getState":@@ -203,7 +207,7 @@ export function registerWindowIpc({maximized: !mainWindow.isDestroyed() && mainWindow.isMaximized(),// The surface this window was created with, so a Settings switch can tell// whether the stored preference has taken effect (#1064 / ADR 0332).- macosWindowTranslucency: isMacosWindowTranslucent(),+ macosWindowTranslucency,};});diff --git a/apps/desktop/src/components/settings/MacosWindowTranslucencyRow.tsx b/apps/desktop/src/components/settings/MacosWindowTranslucencyRow.tsxindex d74b2b7c2..234b8e801 100644--- a/apps/desktop/src/components/settings/MacosWindowTranslucencyRow.tsx+++ b/apps/desktop/src/components/settings/MacosWindowTranslucencyRow.tsx@@ -21,7 +21,8 @@ export function MacosWindowTranslucencyRow({saveSettings: (patch: Partial<AppSettings>) => Promise<void>;}) {const { t } = useTranslation();- const translucent = settings.macosWindowTranslucency === true;+ // Translucency is the shipped look, so only an explicit `false` turns it off.+ const translucent = settings.macosWindowTranslucency !== false;// `null` until the running window reports its surface; an unreadable state// keeps the hint hidden rather than claiming a restart is needed.const [applied, setApplied] = useState<boolean | null>(null);diff --git a/apps/desktop/test/macos-window-translucency.test.mjs b/apps/desktop/test/macos-window-translucency.test.mjsindex 430c2cfca..8b1eb6a51 100644--- a/apps/desktop/test/macos-window-translucency.test.mjs+++ b/apps/desktop/test/macos-window-translucency.test.mjs@@ -19,12 +19,16 @@ const [sharedTypes, settingsSource, windowSource, lifecycleSource, mainStateSourreadMainModule("bootstrap/startup.ts"),]);-test("the macOS translucency preference is an optional, off-by-default setting", () => {+test("the macOS translucency preference is a stored opt-out of the default surface", () => {assert.match(sharedTypes, /macosWindowTranslucency\?: boolean;/);- assert.match(mainStateSource, /macosWindowTranslucency = false;/);+ // The store defaults to the shipped translucent surface, so a boot without+ // settings still paints the window the user expects.+ assert.match(mainStateSource, /macosWindowTranslucency = true;/);+ // Absent means the shipped translucency; only an explicit `false` asks for+ // the cheaper opaque surface.assert.match(lifecycleSource,- /state\.macosWindowTranslucency =\s*process\.platform === "darwin" && settings\?\.macosWindowTranslucency === true;/,+ /state\.macosWindowTranslucency =\s*process\.platform === "darwin" && settings\?\.macosWindowTranslucency !== false;/,);// The value is read where the window is created, before Electron fixes the// surface, and it comes from the settings the boot sequence applied.@@ -32,6 +36,20 @@ test("the macOS translucency preference is an optional, off-by-default setting",assert.match(startupSource, /applyMacosWindowTranslucency\(stored\);/);});+test("creating a translucent macOS window does not repaint its surface opaque", () => {+ // `applyMainWindowBackground` runs right after the window exists. On darwin it+ // must stay out of a translucent window, or the vibrancy glass is flattened+ // before it is ever shown.+ const backgroundCall =+ windowSource.match(+ /if \(!\(process\.platform === "darwin" && windowState\.macosWindowTranslucency\)\) \{\s*applyMainWindowBackground\(/,+ )?.[0] ?? "";+ assert.ok(+ backgroundCall,+ "the post-creation background paint must skip a translucent macOS window",+ );+});+test("a running window cannot switch surfaces, so the preference waits for a launch", async () => {const applyBody =lifecycleSource.match(/function applyMacosWindowTranslucency\([\s\S]*?\n \}/)?.[0] ?? "";@@ -45,7 +63,9 @@ test("a running window cannot switch surfaces, so the preference waits for a lauwindowIpc,/process\.platform === "darwin" && isMacosWindowTranslucent\(\)/,);- assert.match(windowIpc, /macosWindowTranslucency: isMacosWindowTranslucent\(\)/);+ // The renderer reads the surface this process created, and a non-macOS window+ // reports `false` rather than inheriting a platform-independent default.+ assert.match(windowIpc, /const macosWindowTranslucency =\s*process\.platform === "darwin" && isMacosWindowTranslucent\(\);/);});test("the switch is macOS-only and says when a restart is needed", async () => {@@ -54,7 +74,7 @@ test("the switch is macOS-only and says when a restart is needed", async () => {settingsSource,/platform === "darwin" && \(\s*<MacosWindowTranslucencyRow settings=\{settings\} saveSettings=\{saveSettings\} \/>/,);- assert.match(row, /settings\.macosWindowTranslucency === true/);+ assert.match(row, /settings\.macosWindowTranslucency !== false/);assert.match(row, /saveSettings\(\{ macosWindowTranslucency: !translucent \}\)/);assert.match(row, /t\("settings\.windowTranslucencyRestart"\)/);assert.match(row, /const \[applied, setApplied\] = useState<boolean \| null>\(null\)/);diff --git a/apps/desktop/test/window-background.test.mjs b/apps/desktop/test/window-background.test.mjsindex 99d5107f0..b955c5320 100644--- a/apps/desktop/test/window-background.test.mjs+++ b/apps/desktop/test/window-background.test.mjs@@ -42,7 +42,7 @@ test("constructor backgrounds use opaque macOS and Windows 11 surfaces", () => {});});-test("macOS surfaces are opaque by default and translucent only on request", () => {+test("macOS surfaces follow the translucency flag", () => {// Absent/false keeps the window out of WindowServer's per-frame// recomposition path (issue #1064).assert.deepEqual(macosWindowSurfaceOptions(false, "#12345680"), {diff --git a/docs/adr/0248-plugin-theme-assets-and-window-background.md b/docs/adr/0248-plugin-theme-assets-and-window-background.mdindex e3bfc59a2..8c1482c94 100644--- a/docs/adr/0248-plugin-theme-assets-and-window-background.md+++ b/docs/adr/0248-plugin-theme-assets-and-window-background.md@@ -74,12 +74,12 @@ applied at all.macOS keeps its `vibrancy` plate and never receives a colour, matching theexisting rule that darwin does not download one.-> **Superseded in part by ADR 0332.** macOS now paints an opaque native window-> surface instead of a vibrancy plate, so `windowAppearance.backgroundColor` is-> applied on darwin like every other platform. The permission, the derived-not--> remembered restoration, and the palette resolution above are unchanged. With-> `settings.macosWindowTranslucency` on, the window is a vibrancy surface again-> and the colour is skipped for the same reason it was skipped before.+> **Amended by ADR 0332.** macOS keeps its translucent vibrancy surface by+> default, so `windowAppearance.backgroundColor` is skipped there exactly as+> described above; turning off `settings.macosWindowTranslucency` paints the+> opaque native surface and applies the colour like every other platform. The+> permission, the derived-not-remembered restoration, and the palette resolution+> above are unchanged.Permission: new `ui.window.appearance`, confirmed at install and shown in theSettings permission list. A declaration without the grant is audited anddiff --git a/docs/adr/0332-macos-opaque-window-surface.md b/docs/adr/0332-macos-opaque-window-surface.mdindex 912b92671..82e5b74b3 100644--- a/docs/adr/0332-macos-opaque-window-surface.md+++ b/docs/adr/0332-macos-opaque-window-surface.md@@ -1,9 +1,9 @@-# ADR 0332: macOS paints an opaque native window surface+# ADR 0332: macOS keeps its translucent window surface with an opaque opt-out- Status: Accepted- Date: 2026-10-16- Deciders: PI-Desktop maintainers-- Related: issue #1064, D665, D304, D348, ADR 0248 (theme assets and window+- Related: issue #1064, D665, D666, D667, D304, D348, ADR 0248 (theme assets and windowbackground), ADR 0260 (plugin runtime theme APIs),`docs/spec/04-ux/07-ui-design-system.md`,`docs/spec/04-ux/08-component-spec.md`@@ -40,61 +40,60 @@ compositor's per-frame path while it was visible and focused.## Decision-macOS paints an opaque native surface. The main window keeps its frameless-`hiddenInset` titlebar, its inset traffic-light position, and the renderer's-glass tint and sheen, but no longer declares `vibrancy`, `visualEffectState`, or-a transparent backing. The window's native background comes from the same-platform helper the other platforms use, so a theme change repaints it instead-of being skipped on `darwin`.+macOS keeps the translucent native surface the product has always shipped, and+the opaque surface is now the opt-out. The main window keeps its frameless+`hiddenInset` titlebar, its inset traffic-light position, its vibrancy material,+and the renderer's glass tint and sheen.- `macosWindowSurfaceOptions(translucent, color)` is the single place that- declares the macOS surface: `false` paints an opaque- `{ transparent: false, backgroundColor }` window, `true` restores- `vibrancy: "sidebar"`, `visualEffectState: "followWindow"`, and the- transparent `#00000000` backing.-- `mainWindowBackgroundOptions("darwin", color)` keeps returning the opaque- surface, so callers that only know a platform never get the material.-- `applyMainWindowBackground` applies the colour on darwin like every other- platform; the `win32` content-view and Windows 11 DWM branches are unchanged.-- `applyNativeThemeSource` re-applies `setVibrancy("sidebar")` only when the- running window is translucent; an opaque window has no material to reset.-- The `window.setBackgroundColor` IPC applies the colour on darwin unless the- running window is translucent — a vibrancy surface keeps its transparent- pixels, while an opaque one takes a plugin theme's- `windowAppearance.backgroundColor` (ADR 0248) for the palette the renderer- resolved.--`AppSettings.macosWindowTranslucency` opts back into the material on macOS. It-is read once, before `new BrowserWindow`, because Electron fixes `transparent`-at creation: absent and `false` mean the opaque default, and a change is-persisted for the next launch instead of mutating the window on screen. The-Settings switch is darwin-only and shows a restart hint while the stored value-differs from the surface the running process was created with.+ declares the macOS surface: `true` keeps `vibrancy: "sidebar"`,+ `visualEffectState: "followWindow"`, and the transparent `#00000000` backing;+ `false` paints an opaque `{ transparent: false, backgroundColor }` window that+ stays out of WindowServer's per-frame recomposition path (#1064).+- `AppSettings.macosWindowTranslucency` is the stored preference. Absent and+ `true` mean the shipped translucent surface; only `false` asks for the cheaper+ opaque one. It is read once, before `new BrowserWindow`, because Electron+ fixes `transparent` at creation, so a change is persisted for the next launch+ instead of mutating the window on screen. The Settings switch is darwin-only+ and shows a restart hint while the stored value differs from the surface the+ running process was created with.+- A translucent window owns its pixels: the post-creation background paint, the+ `window.setBackgroundColor` IPC, and `applyMainWindowBackground` all leave it+ alone. Painting a host or plugin palette over a transparent backing flattens+ the material, which is also what made an "enabled" switch look ignored. The+ opaque surface takes the colour on darwin like every other platform, so a+ plugin theme's `windowAppearance.backgroundColor` (ADR 0248) applies there.+- `applyNativeThemeSource` re-applies `setVibrancy("sidebar")` for a translucent+ window when the theme source changes; an opaque one has no material to reset.+- `mainWindowBackgroundOptions("darwin", color)` still describes the opaque+ surface, so a caller that only knows a platform never gets the material.The renderer-side sidebar treatment is unchanged: `--ds-sidebar-glass-tint` and-the sheen still paint the sidebar, splash, and rail so the surface keeps-reading as glass. The tint is now composited over the opaque host palette-rather than over a live blur, which is what keeps the visual language intact-without the per-frame material cost.+the sheen paint the sidebar, splash, and rail over whichever surface the window+has, so the glass reads the same and the setting only changes what shows+through it.## Consequences-- An idle focused window returns to the desktop GPU baseline: after the change- the same measurement showed the focused-idle case matching the idle baseline- instead of ~40%.-- macOS can still show the live wallpaper blur: the opt-in restores the- material, and with it WindowServer's per-frame recomposition cost while the- window is visible and focused. The tint and sheen are the same in both- surfaces, so only the translucency to desktop content changes.-- Plugins with a granted `ui.window.appearance` permission now have their- `windowAppearance.backgroundColor` applied on macOS, matching Windows and- Linux. Previously darwin silently ignored it because vibrancy owned the- surface (ADR 0248 said darwin "never receives a colour"; that exclusion is- superseded).-- The bounded-animation contract from #1064 stays in force. Its rationale text- referenced the transparent/vibrancy window, which no longer describes the- window; the rule itself (no unbounded idle animation) is still required- because a dirty window is recomposited on every platform.+- Default installs still pay the compositor cost of the material: translucency+ is the shipped look, so the per-frame recomposition described in Context+ remains for anyone who leaves the switch on. That is a product decision, not+ an oversight — the desktop blur is part of the window's language, and a+ default that silently dropped it changed the app under existing users.+- Turning the switch off paints the opaque surface and returns an idle focused+ window to the desktop GPU baseline measured under #1064. The setting is an+ opt-out, so the saving is one launch away without editing files or starting+ the app differently.+- The renderer tint, sheen, and layout are identical on both surfaces, so the+ switch changes only whether the desktop shows through; no other visual,+ persisted-data, or plugin contract changes.+- Plugins with a granted `ui.window.appearance` permission have their+ `windowAppearance.backgroundColor` applied on the opaque surface, matching+ Windows and Linux, and keep the vibrancy material on the translucent one —+ the same rule as before the setting existed (ADR 0248).+- The bounded-animation contract from #1064 stays in force on both surfaces. A+ dirty window is recomposited on every platform, and on macOS the material+ still multiplies that cost.## Alternatives rejected@@ -114,9 +113,10 @@ without the per-frame material cost.opaque window that can never show the material. Persisting the preference forthe next launch keeps one rendering path per process instead of ahalf-applied state.-- **Make the opaque surface opt-in behind a setting.** Rejected as the- *starting* point: the load is present on default installs, so the default- stays opaque and translucency is the explicit opt-in (see Decision).+- **Make the opaque surface the default.** Tried and reverted: an idle focused+ window stopped costing GPU time, but every existing user lost the material+ their window was designed around. The cost belongs behind a switch the user+ can see, not behind a silent default change.## Evidencediff --git a/docs/adr/README.md b/docs/adr/README.mdindex 9ba489be5..f1701486a 100644--- a/docs/adr/README.md+++ b/docs/adr/README.md@@ -381,4 +381,4 @@ Each ADR includes:| plugin-fetch-redirect-policy | [Host-enforced plugin fetch redirect policy](plugin-fetch-redirect-policy.md) | Accepted (implementation candidate for #1475) || local-agent-remote-workspace-tools | [Local Agent and model requests for remote workspaces](local-agent-remote-workspace-tools.md) | Accepted for implementation |-| 0332 | [macOS paints an opaque native window surface](0332-macos-opaque-window-surface.md) | Accepted (D665; supersedes the macOS vibrancy window backing from D348; issue #1064) |+| 0332 | [macOS keeps its translucent window surface with an opaque opt-out](0332-macos-opaque-window-surface.md) | Accepted (D665, amended by D666 and D667; supersedes the macOS vibrancy window backing from D348; issue #1064) |diff --git a/docs/spec/04-ux/06-settings-ia.md b/docs/spec/04-ux/06-settings-ia.mdindex 83fa6af66..3b3126aa4 100644--- a/docs/spec/04-ux/06-settings-ia.md+++ b/docs/spec/04-ux/06-settings-ia.md@@ -161,9 +161,9 @@ Settings is a **full-window page** that replaces the app sidebar + main chrome (In/Out/Reset stays independent. The UI never asks for a px value(D343 / ADR 0180)- **Translucent window** (macOS only): one switch for the native window- surface (ADR 0332). Off — and absent — keeps the opaque surface that frees- the window from WindowServer's per-frame recomposition; on restores the- `sidebar` vibrancy material behind a transparent backing. It persists as+ surface (ADR 0332). On — and absent — keeps the shipped `sidebar` vibrancy+ material behind a transparent backing; off paints the opaque surface that+ frees the window from WindowServer's per-frame recomposition. It persists as`AppSettings.macosWindowTranslucency` and is applied when the main window iscreated, so the row shows a restart hint while the stored value differs fromthe surface this process launched with instead of pretending to change thediff --git a/docs/spec/04-ux/07-ui-design-system.md b/docs/spec/04-ux/07-ui-design-system.mdindex 51d7a059a..f681f6b3c 100644--- a/docs/spec/04-ux/07-ui-design-system.md+++ b/docs/spec/04-ux/07-ui-design-system.md@@ -754,9 +754,10 @@ plain status text:- Reduced motion: near-zero enter/exit and a static full-width bar- macOS: the splash uses the same sidebar treatment as the app shell (D304 /D348) — the `--ds-sidebar-glass-tint` fill plus top/bottom sheen over the- native surface (ADR 0332 superseded the `sidebar` vibrancy plate; the- `Translucent window` setting brings the plate back), so- the boot surface never flashes a mismatched panel ahead of the sidebar. The+ native `sidebar` vibrancy material, so the boot surface never flashes a+ mismatched panel ahead of the sidebar. Turning off the macOS `Translucent+ window` switch paints an opaque native surface (ADR 0332) under the same tint+ and sheen, and the splash keeps following whichever surface the window has. Themounted shell stays hidden under the splash until the exit fade, thencross-fades in. Other platforms keep the opaque `--ds-bg-primary` filldiff --git a/docs/spec/04-ux/08-component-spec.md b/docs/spec/04-ux/08-component-spec.mdindex f9c5dfe1a..5115e5630 100644--- a/docs/spec/04-ux/08-component-spec.md+++ b/docs/spec/04-ux/08-component-spec.md@@ -150,34 +150,34 @@ Outer frame that positions Topbar, Sidebar, MainChat, and WorkPanel. Owns resize| Windows | Frameless 46px titlebar; sidebar actions at left; work-panel toggle then minimize/maximize/close stay viewport-fixed at the window's top-right | None inside the window || Linux | Frameless 46px titlebar; sidebar actions at left; work-panel toggle then minimize/maximize/close stay viewport-fixed at the window's top-right | None inside the window |-- macOS paints an **opaque** native window surface (ADR 0332). It deliberately- does not use Electron's `vibrancy` material or a transparent window backing:- a material behind a transparent surface is recomposited by WindowServer on- every frame the window stays dirty, which held an idle focused window near- 40% GPU on Apple Silicon (issue #1064). `nativeTheme.themeSource` still follows- the app theme preference (`system` / `light` / `dark` / plugin base), and the- opaque background is repainted from that preference so the native plate always- matches the renderer; a missing plugin theme falls back to `system`. Main and- settings navigation share the+- macOS paints a **translucent** native window surface (ADR 0332): the native+ `vibrancy: "sidebar"` material with `visualEffectState: "followWindow"` behind+ a transparent Electron backing. A material behind a transparent surface is+ recomposited by WindowServer on every frame the window stays dirty, which held+ an idle focused window near 40% GPU on Apple Silicon (issue #1064); the+ `Translucent window` switch is the opt-out for that cost, not the way back to+ the shipped look. `nativeTheme.themeSource` still follows the app theme+ preference (`system` / `light` / `dark` / plugin base), and a missing plugin+ theme falls back to `system`. Main and settings navigation share the`.sidebar-surface` material, alongside any rendered `.sidebar-rail`; thesettings shell ancestry is transparent but its content pane and titlebar stayopaque. The renderer adds a thin theme tint(`--ds-sidebar-glass-tint`, 40% dark / 55% light) plus a top/bottom sheen.The dock carries no seam or hairline: the sidebar meets the opaque main paneflush, so the only edge cue is the tint's natural change against the pane.- With no live material behind it the tint is a paint, not a window onto a- blur, so it must stay thin enough that the sheen — not the fill — keeps the- surface reading as glass rather than a painted panel.+ The material carries the blur, so the tint must stay thin — the sheen is what+ keeps the surface reading as glass rather than a painted panel.`.main-pane`, `.main-titlebar`, and `.conversation-topbar` remain opaque- `bg-primary` surfaces, so the sidebar treatment does not spread across the- whole window.+ `bg-primary` surfaces, so vibrancy does not spread across the whole window.Windows/Linux retain their existing opaque background and frameless behavior.-- Settings → General → Appearance → **Translucent window** (macOS only) opts- back into the `sidebar` vibrancy material behind a transparent backing. The- choice is read when the main window is created, so the row shows a restart- hint until the app is relaunched; both surfaces keep the same tint and sheen,- and while the window is translucent the `window.setBackgroundColor` IPC leaves- the surface to the material (a plugin theme colour is not painted over it).+- Settings → General → Appearance → **Translucent window** (macOS only) is on+ by default and turns the material off: an opaque window paints the host or+ plugin palette and leaves WindowServer's per-frame recomposition path, while+ the renderer keeps the same tint and sheen. The choice is read when the main+ window is created, so the row shows a restart hint until the app is+ relaunched. A translucent window owns its pixels — neither the+ `window.setBackgroundColor` IPC nor the post-creation background paint touches+ it, because a colour over the transparent backing flattens the material.- The macOS system menu exposes New Task, Open Project, Settings, CommandPalette, Sidebar, standard editing, zoom/fullscreen, window, Help, Logs, andCheck for Updates actions. Windows/Linux expose equivalent product actionsdiff --git a/docs/spec/07-plugins/13-plugin-permissions-matrix.md b/docs/spec/07-plugins/13-plugin-permissions-matrix.mdindex 197954fb1..a597b753c 100644--- a/docs/spec/07-plugins/13-plugin-permissions-matrix.md+++ b/docs/spec/07-plugins/13-plugin-permissions-matrix.md@@ -12,7 +12,7 @@ Provide a permission–capability–risk–default-policy reference table for re| `ui.view` | low | `contributes.views` are listed in the work panel and may be opened | Granted at install | Same isolation as a panel window: sandboxed page, per-plugin partition, `net.domains` egress. Filtered by activation scope || `ui.theme` | low | `contributes.themes` CSS is loaded and offered in Settings; runtime `pi.themes.upsert` / `remove` / `list` and `pi.app.setTheme` (ADR 0260) | Granted at install | CSS is sanitized by the host; it cannot script. Declared `assets` are served over the host's read-only `plugin-asset:` scheme. `setTheme` may only select a built-in preference or a currently registered plugin theme. There is no per-plugin theme count cap || `ui.settings` | low | `contributes.settingsDestinations` adds a sandboxed Settings entry in Extensions | Granted at install | Rendered only in host Extensions group; isolated view host with same sandbox as panel views (ADR 0261) |-| `ui.window.appearance` | low | `contributes.windowAppearance` sets the native window background and Windows main-window corner request while one of the plugin's themes is selected | Granted at install | `#rrggbb` / `#rrggbbaa` background and integer `cornerRadius` 0..24 DIP; restores host background and the 12 DIP default request when the theme is gone. Windows 11 maps 0 to square and positive values to the system-rounded preference (not exact DIP radii); alpha is composited over the built-in theme color on its opaque window. Earlier Windows builds retain the requested DIP radius. macOS applies the background to its opaque native surface (ADR 0332) and keeps native corners; with the `Translucent window` setting on, the vibrancy surface ignores the colour |+| `ui.window.appearance` | low | `contributes.windowAppearance` sets the native window background and Windows main-window corner request while one of the plugin's themes is selected | Granted at install | `#rrggbb` / `#rrggbbaa` background and integer `cornerRadius` 0..24 DIP; restores host background and the 12 DIP default request when the theme is gone. Windows 11 maps 0 to square and positive values to the system-rounded preference (not exact DIP radii); alpha is composited over the built-in theme color on its opaque window. Earlier Windows builds retain the requested DIP radius. macOS keeps native corners; its default translucent vibrancy surface ignores the colour, and the `Translucent window` switch turned off applies it to the opaque native surface (ADR 0332) || `clipboard.read` | medium | `clipboard.readText`, `clipboard.getHistory` | Confirm on first use | May read sensitive information and retained clipboard history || `clipboard.write` | medium | `clipboard.writeText` | Confirm on first use | Prevents clipboard pollution || `notify` | low | `ui.notify`, `ui.getNotificationPermission`, `ui.requestNotificationPermission`, `ui.showNativeNotification` | Can be granted by default | Native delivery is OS-controlled; avoid notification-spam abuse |diff --git a/docs/spec/08-meta/decisions-log.md b/docs/spec/08-meta/decisions-log.mdindex 1790714d5..1ea52e8ff 100644--- a/docs/spec/08-meta/decisions-log.md+++ b/docs/spec/08-meta/decisions-log.md@@ -7802,7 +7802,7 @@ must keep splitting are covered by `markdown-blocks.test.mjs`.`apps/desktop/test/window-background-theme.test.mjs`, and`apps/desktop/test/idle-status-animations.test.mjs`.-## 2026-10-20 — macOS translucency is an opt-in window setting (D666)+## 2026-10-20 — macOS translucency is a window setting (D666, amended by D667)- D666 amends D665 / ADR 0332: the macOS main window still paints an opaquenative surface by default, and `AppSettings.macosWindowTranslucency` lets a@@ -7819,8 +7819,31 @@ must keep splitting are covered by `markdown-blocks.test.mjs`.surface to the material, so a plugin theme's`windowAppearance.backgroundColor` is applied only on the opaque surface. Therenderer tint and sheen are unchanged in both modes, and no persisted-format- migration is required: an absent value means opaque.+ migration is required (D667 changed the absent-value meaning to translucent).- Covered by `apps/desktop/test/macos-window-translucency.test.mjs`,`apps/desktop/test/macos-opaque-window-surface.test.mjs`, and`apps/desktop/test/window-background.test.mjs`. See ADR 0332,`04-ux/08-component-spec.md`, and `04-ux/07-ui-design-system.md`.++## 2026-10-20 — macOS translucency stays the default (D667)++- D667 amends D665 / D666 and ADR 0332: the macOS main window ships+ **translucent** again — `vibrancy: "sidebar"`, `visualEffectState:+ "followWindow"`, and a transparent `#00000000` backing — and+ `AppSettings.macosWindowTranslucency` is the opt-out. Absent and `true` mean+ the shipped material; only `false` paints the opaque surface that leaves+ WindowServer's per-frame recomposition path (#1064). The store itself defaults+ to translucent, so a boot that cannot read settings still paints the expected+ window.+- A translucent window owns its pixels: the post-creation+ `applyMainWindowBackground` call now skips macOS windows created translucent,+ in addition to the already-guarded `window.setBackgroundColor` and theme paths.+ Without that guard the window was created with the material and then had an+ opaque host colour painted over it, so the switch looked inert after a restart.+ `window/control` `getState` keeps reporting the surface the process actually+ created, which keeps the Settings restart hint honest.+- No persisted migration: an absent value now means translucent, which restores+ the pre-D665 appearance for every existing install, and an explicit `false`+ keeps the opaque choice a user already made. See ADR 0332, ADR 0248,+ `04-ux/06-settings-ia.md`, `04-ux/08-component-spec.md`, and+ `apps/desktop/test/macos-window-translucency.test.mjs`.diff --git a/packages/i18n/src/locales/de/index.ts b/packages/i18n/src/locales/de/index.tsindex 961b7b143..3ee5d487a 100644--- a/packages/i18n/src/locales/de/index.ts+++ b/packages/i18n/src/locales/de/index.ts@@ -1434,7 +1434,7 @@ sklm: {"preventScreenSleep": "Bildschirmsperre verhindern","preventScreenSleepDesc": "Hält das Display wach, solange die App läuft. Nutzt plattformübergreifend die System-Energieverwaltung.","windowTranslucency": "Transparentes Fenster",- "windowTranslucencyDesc": "Hält das macOS-Fenster über der Unschärfe des Schreibtischs transparent. Kostet mehr GPU, solange das Fenster sichtbar ist; für die geringste Leerlauflast ausschalten.",+ "windowTranslucencyDesc": "Hält das macOS-Fenster über der Unschärfe des Schreibtischs transparent; das ist die Voreinstellung. Kostet mehr GPU, solange das Fenster sichtbar ist; für die geringste Leerlauflast ausschalten. Die Änderung greift nach einem Neustart.","windowTranslucencyRestart": "Zum Anwenden neu starten","linkOpenTarget": "Ziel für Link-Öffnung","linkOpenTargetWorkpanel": "Arbeitsbereich-Browser",diff --git a/packages/i18n/src/locales/en/index.ts b/packages/i18n/src/locales/en/index.tsindex 5f2610c79..a28e4dc3b 100644--- a/packages/i18n/src/locales/en/index.ts+++ b/packages/i18n/src/locales/en/index.ts@@ -1448,7 +1448,7 @@ sklm: {preventScreenSleep: "Prevent screen sleep",preventScreenSleepDesc: "Keep the display awake while the app is running. Uses system power management APIs on all platforms.",windowTranslucency: "Translucent window",- windowTranslucencyDesc: "Keep the macOS window translucent over the desktop blur. It costs more GPU while the window is visible; turn it off for the lowest idle load.",+ windowTranslucencyDesc: "Keep the macOS window translucent over the desktop blur, which is the default. It costs more GPU while the window is visible; turn it off for an opaque window with the lowest idle load. A change applies after a restart.",windowTranslucencyRestart: "Restart to apply",linkOpenTarget: "Link open destination",linkOpenTargetWorkpanel: "Work panel browser",diff --git a/packages/i18n/src/locales/es/index.ts b/packages/i18n/src/locales/es/index.tsindex 46bfa7a4d..dab1dccc4 100644--- a/packages/i18n/src/locales/es/index.ts+++ b/packages/i18n/src/locales/es/index.ts@@ -1434,7 +1434,7 @@ sklm: {"preventScreenSleep": "Evitar suspensión de pantalla","preventScreenSleepDesc": "Mantiene la pantalla encendida mientras la aplicación está en ejecución. Usa las API de gestión de energía del sistema en todas las plataformas.","windowTranslucency": "Ventana translúcida",- "windowTranslucencyDesc": "Mantiene la ventana de macOS translúcida sobre el desenfoque del escritorio. Usa más GPU mientras la ventana está visible; desactívalo para la menor carga en reposo.",+ "windowTranslucencyDesc": "Mantiene la ventana de macOS translúcida sobre el desenfoque del escritorio; es el valor predeterminado. Usa más GPU mientras la ventana está visible; desactívalo para una ventana opaca con la menor carga en reposo. El cambio se aplica tras reiniciar.","windowTranslucencyRestart": "Reinicia para aplicar","linkOpenTarget": "Destino al abrir enlaces","linkOpenTargetWorkpanel": "Navegador del panel de trabajo",diff --git a/packages/i18n/src/locales/fr/index.ts b/packages/i18n/src/locales/fr/index.tsindex 39c0c6bff..701530342 100644--- a/packages/i18n/src/locales/fr/index.ts+++ b/packages/i18n/src/locales/fr/index.ts@@ -1434,7 +1434,7 @@ sklm: {"preventScreenSleep": "Empêcher la mise en veille","preventScreenSleepDesc": "Garde l'écran allumé tant que l'application est ouverte. Utilise les API de gestion d'énergie du système sur toutes les plateformes.","windowTranslucency": "Fenêtre translucide",- "windowTranslucencyDesc": "Garde la fenêtre macOS translucide sur le flou du bureau. Consomme plus de GPU tant que la fenêtre est visible ; désactivez pour une charge au repos minimale.",+ "windowTranslucencyDesc": "Garde la fenêtre macOS translucide sur le flou du bureau ; c'est le réglage par défaut. Consomme plus de GPU tant que la fenêtre est visible ; désactivez pour une fenêtre opaque et une charge au repos minimale. Le changement s'applique après un redémarrage.","windowTranslucencyRestart": "Redémarrer pour appliquer","linkOpenTarget": "Destination d'ouverture des liens","linkOpenTargetWorkpanel": "Navigateur du panneau de travail",diff --git a/packages/i18n/src/locales/ko/index.ts b/packages/i18n/src/locales/ko/index.tsindex 3f985dceb..e4e1d2c10 100644--- a/packages/i18n/src/locales/ko/index.ts+++ b/packages/i18n/src/locales/ko/index.ts@@ -1444,7 +1444,7 @@ sklm: {preventScreenSleep: "화면 절전 방지",preventScreenSleepDesc: "앱이 실행되는 동안 화면이 꺼지지 않도록 합니다. 모든 플랫폼에서 시스템 전원 관리 API를 사용합니다.",windowTranslucency: "반투명 창",- windowTranslucencyDesc: "macOS 창을 데스크톱 흐림 위에 반투명하게 유지합니다. 창이 보이는 동안 GPU를 더 사용하므로 유휴 부하를 가장 낮추려면 끄세요.",+ windowTranslucencyDesc: "macOS 창을 데스크톱 흐림 위에 반투명하게 유지합니다(기본값). 창이 보이는 동안 GPU를 더 사용하므로, 유휴 부하를 가장 낮추려면 끄세요. 변경 사항은 재시작 후 적용됩니다.",windowTranslucencyRestart: "적용하려면 재시작",linkOpenTarget: "링크 열기 위치",linkOpenTargetWorkpanel: "작업 패널 브라우저",diff --git a/packages/i18n/src/locales/pt-BR/index.ts b/packages/i18n/src/locales/pt-BR/index.tsindex d5f633f82..54f3e679b 100644--- a/packages/i18n/src/locales/pt-BR/index.ts+++ b/packages/i18n/src/locales/pt-BR/index.ts@@ -1407,7 +1407,7 @@ export const ptBR = {preventScreenSleep: "Impedir suspensão da tela",preventScreenSleepDesc: "Mantém a tela ligada enquanto o app está em execução. Usa as APIs de gerenciamento de energia do sistema em todas as plataformas.",windowTranslucency: "Janela translúcida",- windowTranslucencyDesc: "Mantém a janela do macOS translúcida sobre o desfoque da área de trabalho. Usa mais GPU enquanto a janela está visível; desative para a menor carga ociosa.",+ windowTranslucencyDesc: "Mantém a janela do macOS translúcida sobre o desfoque da área de trabalho, que é o padrão. Usa mais GPU enquanto a janela está visível; desative para uma janela opaca com a menor carga ociosa. A alteração vale após reiniciar.",windowTranslucencyRestart: "Reiniciar para aplicar",linkOpenTarget: "Destino ao abrir links",linkOpenTargetWorkpanel: "Navegador do painel de trabalho",diff --git a/packages/i18n/src/locales/tr/index.ts b/packages/i18n/src/locales/tr/index.tsindex 2b937638b..b8989edac 100644--- a/packages/i18n/src/locales/tr/index.ts+++ b/packages/i18n/src/locales/tr/index.ts@@ -1438,7 +1438,7 @@ sklm: {preventScreenSleep: "Ekran uykusunu engelle",preventScreenSleepDesc: "Uygulama çalışırken ekranı açık tutar. Tüm platformlarda sistem güç yönetimi API'lerini kullanır.",windowTranslucency: "Saydam pencere",- windowTranslucencyDesc: "macOS penceresini masaüstü bulanıklığı üzerinde saydam tutar. Pencere görünürken daha fazla GPU kullanır; en düşük boşta yük için kapatın.",+ windowTranslucencyDesc: "macOS penceresini masaüstü bulanıklığı üzerinde saydam tutar; varsayılan budur. Pencere görünürken daha fazla GPU kullanır; en düşük boşta yük için kapatın. Değişiklik yeniden başlatmadan sonra uygulanır.",windowTranslucencyRestart: "Uygulamak için yeniden başlatın",linkOpenTarget: "Bağlantı açma hedefi",linkOpenTargetWorkpanel: "Çalışma paneli tarayıcısı",diff --git a/packages/i18n/src/locales/zh-CN/index.ts b/packages/i18n/src/locales/zh-CN/index.tsindex 7cc114f95..7c026ae18 100644--- a/packages/i18n/src/locales/zh-CN/index.ts+++ b/packages/i18n/src/locales/zh-CN/index.ts@@ -1428,7 +1428,7 @@ sklm: {preventScreenSleep: "阻止屏幕休眠",preventScreenSleepDesc: "应用运行时保持屏幕常亮,跨平台使用系统电源管理接口。",windowTranslucency: "窗口透明效果",- windowTranslucencyDesc: "让 macOS 窗口保持透明并显示桌面模糊背景。窗口可见时占用更多 GPU;关闭可让空闲占用最低。",+ windowTranslucencyDesc: "让 macOS 窗口保持透明并显示桌面模糊背景(默认开启)。窗口可见时会占用更多 GPU;关闭后使用不透明窗口,空闲占用最低。修改后需重启生效。",windowTranslucencyRestart: "重启后生效",linkOpenTarget: "链接打开位置",linkOpenTargetWorkpanel: "工作区浏览器",diff --git a/packages/i18n/src/locales/zh-TW/index.ts b/packages/i18n/src/locales/zh-TW/index.tsindex 587843e4a..1ae7643a6 100644--- a/packages/i18n/src/locales/zh-TW/index.ts+++ b/packages/i18n/src/locales/zh-TW/index.ts@@ -1428,7 +1428,7 @@ sklm: {preventScreenSleep: "防止螢幕休眠",preventScreenSleepDesc: "應用程式執行時保持螢幕常亮,跨平台使用系統電源管理介面。",windowTranslucency: "視窗透明效果",- windowTranslucencyDesc: "讓 macOS 視窗保持透明並顯示桌面模糊背景。視窗可見時佔用更多 GPU;關閉可讓閒置佔用最低。",+ windowTranslucencyDesc: "讓 macOS 視窗保持透明並顯示桌面模糊背景(預設開啟)。視窗可見時會佔用更多 GPU;關閉後使用不透明視窗,閒置佔用最低。修改後需重新啟動生效。",windowTranslucencyRestart: "重新啟動後生效",linkOpenTarget: "連結開啟位置",linkOpenTargetWorkpanel: "工作區瀏覽器",diff --git a/packages/shared/src/types/settings.ts b/packages/shared/src/types/settings.tsindex c04a0b61d..133d21482 100644--- a/packages/shared/src/types/settings.ts+++ b/packages/shared/src/types/settings.ts@@ -77,10 +77,12 @@ export type AppSettings = {theme: ThemePreference;/*** macOS only: keep the native `sidebar` vibrancy material behind a- * transparent window surface. Absent and false paint an opaque surface,- * which keeps the window out of WindowServer's per-frame recomposition path- * (#1064). Other platforms ignore it. Electron fixes `transparent` when the- * window is created, so a change applies on the next launch.+ * transparent window surface. This is the shipped look, so absent and `true`+ * both mean translucent; `false` paints an opaque surface, which keeps the+ * window out of WindowServer's per-frame recomposition path (#1064) at the+ * cost of the desktop blur. Other platforms ignore it. Electron fixes+ * `transparent` when the window is created, so a change applies on the next+ * launch.*/macosWindowTranslucency?: boolean;/** UI language; `auto` (and absent) follows the OS locale. */