Repository navigation
perf(renderer): keep modal blur with independent source regions - #33799
Conversation
|
Note Reviews pausedIt looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the
Use the following commands to manage reviews:
Use the checkboxes below for quick actions:
No actionable comments were generated in the recent review.
|
There was a problem hiding this comment.
Actionable comments posted: 1

Review info
-
Run configuration-
- Source mode: Auto
- Repository: Unavailable
- Branch: Unavailable
- File: No configuration file from this repository applied
- Commit: Unavailable
- Layers: Repository UI
- Review profile: CHILL
- Plan: Advanced
- Run ID:
89a923c7-ad3d-45d7-9791-1b708c118eda
Files selected for processing: 9-
src/renderer/src/App.tsxsrc/renderer/src/app-shell/AppRootSurfaces.tsxsrc/renderer/src/assets/main.csssrc/renderer/src/components/onboarding/OnboardingFlow.tsxsrc/renderer/src/components/ui/command.tsxsrc/renderer/src/components/ui/dialog.tsxsrc/renderer/src/components/ui/sheet.fixture.tsxsrc/renderer/src/components/ui/sheet.tsxtests/e2e/modal-scene-blur.spec.ts
Files skipped from review as they are similar to previous changes: 2-
- src/renderer/src/components/onboarding/OnboardingFlow.tsx
- src/renderer/src/components/ui/sheet.tsx
Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 8 remain after this review.
-
| body:has(> [data-slot='dialog-overlay'], > [data-slot='sheet-overlay'], > [data-onboarding-overlay]) | ||
| .app-layout | ||
| > :not(.window-controls) { | ||
| filter: blur(2px); |
There was a problem hiding this comment.
🔎 Supported by static analysis
-
Script executed:
git diff 44ac5e284e345d33d0bef02d255906e7a58d2c0b 9c97867596f767da5c609fbc9af8d43bf2d0f200 -- src/renderer/src/assets/main.css src/renderer/src/App.tsx src/renderer/src/app-shell/AppRootSurfaces.tsx tests/e2e/modal-scene-blur.spec.ts sed -n '855,895p' src/renderer/src/assets/main.cssRepository: stablyai/orca
Length of output: 9535
Script executed:
set -eu printf '%s\n' '--- changed CSS and nearby rules ---' nl -ba src/renderer/src/assets/main.css | sed -n '800,905p' printf '%s\n' '--- filter and overlay-related CSS references ---' rg -n -F --glob '*.css' -e 'filter:' -e 'backdrop-filter' -e 'data-onboarding-overlay' -e 'dialog-overlay' -e 'sheet-overlay' -e 'app-layout' src/renderer/src/assets src/renderer/src | sed -n '1,240p' printf '%s\n' '--- portal and overlay-producing references ---' rg -n -F --glob '*.{tsx,ts}' -e 'createPortal' -e 'data-onboarding-overlay' -e 'data-slot="dialog-overlay"' -e "data-slot='dialog-overlay'" -e 'DialogPortal' -e 'SheetPortal' src/renderer/src | sed -n '1,260p' printf '%s\n' '--- app root and shell structure ---' nl -ba src/renderer/src/app-shell/AppRootSurfaces.tsx | sed -n '300,390p' nl -ba src/renderer/src/App.tsx | sed -n '85,125p' printf '%s\n' '--- modal scene test and status-bar references ---' nl -ba tests/e2e/modal-scene-blur.spec.ts | sed -n '1,100p' rg -n -F --glob '*.{tsx,ts,css}' -e 'status-bar' -e 'StatusBar' -e 'usage' -e 'pulse' -e 'animate-' src/renderer/src | sed -n '1,260p'
Repository: stablyai/orca
Length of output: 41746
Script executed:
set -eu printf '%s\n' '--- overlay primitive imports and implementations ---' rg -n -F --glob '*.{tsx,ts}' -e 'from "@radix-ui/react-dialog"' -e "from '@radix-ui/react-dialog'" -e 'DialogPortal' -e 'SheetPortal' -e 'data-slot="dialog-overlay"' -e 'data-slot="sheet-overlay"' src/renderer/src | sed -n '1,220p' printf '%s\n' '--- app root portal block ---' nl -ba src/renderer/src/app-shell/AppRootSurfaces.tsx | sed -n '340,385p' printf '%s\n' '--- changed selectors and test expectations ---' nl -ba src/renderer/src/assets/main.css | sed -n '862,890p' nl -ba tests/e2e/modal-scene-blur.spec.ts | sed -n '20,70p'
Repository: stablyai/orca
Length of output: 8353
Script executed:
set -eu printf '%s\n' '--- dialog primitive ---' nl -ba src/renderer/src/components/ui/dialog.tsx | sed -n '1,145p' printf '%s\n' '--- sheet primitive ---' nl -ba src/renderer/src/components/ui/sheet.tsx | sed -n '1,115p' printf '%s\n' '--- existing overlay rules ---' nl -ba src/renderer/src/assets/main.css | sed -n '475,555p' nl -ba src/renderer/src/assets/main.css | sed -n '930,955p' printf '%s\n' '--- onboarding overlay declaration ---' nl -ba src/renderer/src/components/onboarding/OnboardingFlow.tsx | sed -n '185,215p'
Repository: stablyai/orca
Length of output: 18056
Script executed:
set -eu rg -n -F --glob '*.{tsx,ts}' -e 'Skip onboarding?' -e 'No, keep going' -e 'requestSkipConfirmation' src/renderer/src/components/onboarding
Repository: stablyai/orca
Length of output: 875
Script executed:
set -eu nl -ba src/renderer/src/components/onboarding/OnboardingSkipConfirmationDialog.tsx | sed -n '1,130p'
Repository: stablyai/orca
Length of output: 2407
Remove the scene filters and update the blur assertions.
The dialog and sheet portals render their overlays as direct body children. The first rule therefore applies filter: blur(2px) to the visible workspace.
Onboarding is also portaled to document.body. Its skip confirmation uses DialogContent, so the later dialog overlay matches the sibling selector and blurs the full-screen onboarding content.
This contradicts the sharp-background trade-off. Remove both filters and change the affected E2E expectations from blur(2px) to none.
The source establishes the visual regression, but it does not establish a material GPU-memory consequence.
Suggested CSS fix
-
--- "a/src/renderer/src/assets/main.css" +++ "b/src/renderer/src/assets/main.css" @@ -865,22 +865,6 @@ overflow: hidden; } -/* Blur source regions independently so status-bar animation cannot re-filter the workspace. */ -body:has(> [data-slot='dialog-overlay'], > [data-slot='sheet-overlay'], > [data-onboarding-overlay]) - .app-layout - > :not(.window-controls) { - filter: blur(2px); -} - -body - > :is( - [data-slot='dialog-content'], - [data-slot='command-dialog-content'], - [data-slot='sheet-content'], - [data-onboarding-overlay] - ):has(~ [data-slot='dialog-overlay'], ~ [data-slot='sheet-overlay']) { - filter: blur(2px); -} /* Why: native windows have a stable content box and need no wake-time viewport reflow. */ html.native-shell,
…p pulse A full-window backdrop-filter is re-blurred on every frame while anything beneath it animates, which held ~370 MB of extra GPU render-pass textures and swapchain buffers while a dialog, sheet, palette or onboarding was open. The 2px scrim blur is barely visible under the black scrim, so keep the dim only (5 points darker to keep the background as recessive) and drop the panel blur that sits under a 96%-opaque background. The status-bar usage chip also pulsed forever before its first fetch (unfocused windows never poll); show it static until a fetch is actually running.
4bd95b7 to
972d996
Compare
There was a problem hiding this comment.
🧹 Nitpick comments: 1
src/main/ipc/worktrees-create-first-work-rename.test.ts: 1
52-52:Trivial · Maintainability & Code Quality · Quick win Use typed
importOriginalin the five mock factories.These casts violate the repository rule. No test-specific exception applies. Replace them with the typed
importOriginalform already used in this file. This is a maintainability refactor, not a demonstrated runtime or test failure.Suggested fix
- (await importOriginal()) as Record<string, unknown> + await importOriginal<Record<string, unknown>>()Apply this replacement at lines 52, 57, 62, 67, and 72.

Review info
-
Run configuration-
- Source mode: Auto
- Repository: Unavailable
- Branch: Unavailable
- File: No configuration file from this repository applied
- Commit: Unavailable
- Layers: Repository UI
- Review profile: CHILL
- Plan: Advanced
- Run ID:
aed33108-fcf3-43d2-9d53-bc86fe31cb9b
Files selected for processing: 8-
src/main/ai-vault/session-scanner-pi-omp-shared-root.test.tssrc/main/ipc/worktrees-create-first-work-rename.test.tssrc/main/ipc/worktrees-create-metadata-persistence.test.tssrc/main/runtime/runtime-local-worktree-create-pr-conflict.test.tssrc/main/runtime/runtime-local-worktree-create-test-harness.tssrc/main/runtime/runtime-local-worktree-create.test.tssrc/renderer/src/components/native-chat/NativeChatStructuredPaneMenuItems.tsxsrc/renderer/src/components/native-chat/use-native-chat-context-menu.tsx
Files with no reviewable changes: 1-
- src/main/ipc/worktrees-create-metadata-persistence.test.ts
Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 5 remain after this review.
-
…P screenshots return Windows composites nothing for an idle window that was never shown, so Page.captureScreenshot under ORCA_BACKGROUND_LAUNCH=1 waited forever once the status-bar usage chip stopped animating (#33799).
…P screenshots return Windows composites nothing for an idle window that was never shown, so Page.captureScreenshot under ORCA_BACKGROUND_LAUNCH=1 waited forever once the status-bar usage chip stopped animating (#33799).
…ackground launches (#34197) * fix(window): repaint a never-shown background window on Windows so CDP screenshots return Windows composites nothing for an idle window that was never shown, so Page.captureScreenshot under ORCA_BACKGROUND_LAUNCH=1 waited forever once the status-bar usage chip stopped animating (#33799). * fix(window): pump hidden-window frames from the renderer on Windows background launches Main-process webContents.invalidate() did not make a never-shown Windows window produce a frame CDP can capture (verified on Windows 11). A one-frame root background flip from the preload does, so main stamps a preload flag for ORCA_BACKGROUND_LAUNCH=1 on win32 and tells the preload to stop on first show. * fix(window): stop the hidden-frame pump only on main's show signal, including after reloads A never-shown Windows window can report visible after a desktop change, so the preload no longer stops on visibilitychange; main re-sends the stop after any reload once the window has been shown. * fix(window): register the frame-pump stop with on('show') so every window double supports it createMainWindow suites simulate win32 under the runner's ORCA_BACKGROUND_LAUNCH=1, so they install the pump stop; their window doubles implement on() but not once().












Modal backgrounds keep their 2px blur while avoiding full-window backdrop filtering. The workspace and status bar blur independently, so a status-bar animation cannot invalidate the workspace's filtered surface. Dialog text remains sharp and the original scrim opacity is restored.
Onboarding and notifications render outside the filtered regions. Nested confirmations blur the underlying dialog; closing the final overlay releases all source filters, including after exit animations. Window controls retain their existing stacking. Onboarding render failures keep Retry within the viewport, beneath the automatic crash-report dialog. The no-data usage-chip pulse removal and the removal of nearly opaque panels' redundant backdrop filters remain.
Also removes one stale, unused context-menu import left by an upstream merge, restoring the full CI lint gate.
Where the cheaper blur applies
This is shared main-app modal behavior, rather than an onboarding-only optimization:
The shared CSS watches body-level dialog, sheet, and onboarding overlays and filters the main app's layout regions or the separate Space window's page. Nonmodal sheets without an overlay do not trigger app blur. Small/local backdrop effects in menus, popovers, selects, hover cards, browser controls, and pane-local overlays retain their existing blur.
Resource measurements
Built app, Linux software compositor, hidden 1710×1073 window at 2× scale, fresh isolated profiles. Two interleaved runs per variant, with a rotating status-bar marker. Memory is Linux PSS, which avoids double-counting shared buffers.
Each run warmed for 10 seconds, then sampled for 10 seconds. A 256×160 JPEG preview every tenth frame kept hidden rendering active. The new blur delivered 50–52 previews during the sample; the original delivered 6–7. This is a controlled rendering workload, not an idle-CPU measurement. There is no capture, image cache, timer, or new subscription in the implementation.
These are Linux software-rendering measurements. Native macOS/Windows RAM savings remain unmeasured; the prior description's Mac figures measured disabling blur and do not describe this implementation.
Validation
ORCA_BACKGROUND_LAUNCH=1 pnpm check:changed --maxWorkers=2Visual proof
The screenshots show the ordinary Add a project dialog, demonstrating the shared behavior outside onboarding. Before: the earlier version of this PR dimmed a sharp background. After: the background remains visibly blurred and the dialog remains sharp. Captured through CDP from an isolated, hidden worktree app; the before frame uses the earlier CSS recipe as a runtime comparison.
Onboarding recovery found during review
A forced onboarding render failure previously left Retry below the viewport after dismissing the crash-report dialog. The recovery screen now fills the viewport and Retry restores onboarding. The before control uses the same build with only the new fallback positioning removed; the regression test fails there and passes on the final build.