veritas-kanban/docs/audits/RESPONSIVE-OVERLAY-FOCUS-1445.md

2.7 KiB
Raw Permalink Blame History

Responsive overlay focus (#1445)

Settings retained the HTMLElement that opened it, but Header replaces that element at its compact breakpoint. Returning to desktop width created another button, so dismissal could not restore focus. The browser regression reproduced this at 1440×1000 → 620×650 → 1440×1000 before the fix.

Toolbar actions now have explicit logical focus keys. Overlay dismissal prefers the original usable element, resolves its current keyed replacement when needed, and uses visible Search when the action is absent in the compact toolbar. Disabled, hidden, disconnected, and inert targets are excluded. If another overlay remains open, restoration must stay inside the active overlay. This protects nested dismissal and command-palette handoffs. Unmarked non-toolbar openers keep their existing exact-element behavior.

Five browser checks cover Settings remount and compact fallback, nested confirmation dismissal, both New Task toolbar variants, and palette-to-Settings handoff after resizing. Existing discovery checks cover animated reopening and light/dark handoffs. All eight cases passed across the focused runs. Twelve overlay component tests pass; the nested portal test now uses real portals instead of the Mantine test environment that puts children beneath their inert parents. Web typecheck and changed-file lint pass. Specification and standards reviews found no actionable issues.

The unsigned macOS arm64 candidate built from this change also passed Settings, nested dismissal, New Task, and palette handoff checks in both themes in an isolated synthetic profile. The native window enforces a 1180px minimum width: the 620-CSS-pixel compact case was exercised at 200% zoom in a 1240×1000 content window, not by disabling that minimum. Returning to 1440×1000 at 100% zoom restores the current desktop action. Native window captures show visible Search focus after compact dismissal and focus inside Settings after handoff. Browser screenshot capture cropped the zoomed window, so visual evidence was recaptured through Electron's native window capture API.

Candidate identity: app.isPackaged=true, version 6.1.6, Electron 44.1.1. The application archive SHA-256 is 57e855b0ab4d3a107ada9d9fe5dcdb6aea31e69c6cb73453cd27e195cf4b9aaf; the built renderer entry index-Dz8Nhj3k.js SHA-256 is 9f08deb8aa688e7a05e8aafd7a1837fcac00bd43e506aa58eaccae7f42a83a6b. Local acceptance script and intermediate captures are retained at /tmp/vk-native-focus-1445.vPNgJw/. No messages, provider runs, or destructive Settings actions were submitted.

This change is stacked on the task-overlay work in #1446. It does not complete that parent work, replace the installed application, refresh maintained documentation media, or satisfy the full release gate.