Repository navigation
Preserve composer focus during same-task refreshes - #4108
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Test evidence — same-session-refresh-preserves-composer-focus-and-uninterrupted-typing — 0/0 screenshots passed · 2 assertions✅ 0/0 screenshots passed · 2 assertions · 2 expectations passed · 0 failed · 0 pending
ℹ️ ASSERTION — 1. A same-session completion refresh preserves composer focus and editabilityThe active Lexical editor remained focused and contenteditable after its session snapshot refreshed.
ℹ️ ASSERTION — 2. The existing draft remains intact and typing continues without another clickThe composer preserved “Keep this draft while the task finishes” and accepted the suffix immediately after refresh.
Test run created 2026-08-26T04:35:12.445Z · Source: |
There was a problem hiding this comment.
Warden security clearance: clear. No blocking findings (security or desktop↔den sync) in this diff (19fecb38428ce5f3383bf076e9f21d291b779070). Automated clearance satisfies the required-review gate only — a human still reviews and merges. Analysis run
Summary
Root cause
Every snapshot refetch was classified as a task switch, including completion updates for the task already on screen. That temporarily made the composer non-editable, blurred the editor, and then restored editability without restoring focus.
Verification
bun test --isolate tests/session-transition-controller.test.ts— 3 passed19fecb38428ce5f3383bf076e9f21d291b779070— 1 passed, 0 failed, 0 skipped; 2 assertion claims passed