test: synchronize narrow notes keyboard acceptance on Linux
Cross-platform packages / Validate source (push) Canceled after 0s
Cross-platform packages / Authorize desktop packaging (push) Canceled after 0s
Cross-platform packages / linux arm64 (push) Canceled after 0s
Cross-platform packages / macos arm64 (push) Canceled after 0s
Cross-platform packages / windows arm64 (push) Canceled after 0s
Cross-platform packages / linux x64 (push) Canceled after 0s
Cross-platform packages / macos x64 (push) Canceled after 0s
Cross-platform packages / windows x64 (push) Canceled after 0s
Cross-platform packages / Publish GitHub and OSS release (push) Canceled after 0s

The real Linux Host reproduced Escape being sent to the collapsed workbar
trigger after resize. Wait for the narrow viewport, open the workbar through
its existing control, and confirm the append field owns focus before input.

Keep the migration fixture and all IO assertions, with a 15-second allowance
for its 10000-record scenario. Product behavior and approved notes are unchanged.

Validation: real Linux Host full suite 5345 passed, 51 skipped; Windows focused
3 passed; complete typecheck, lint, and release-note verification passed.
This commit is contained in:
mesalogo
2026-09-28 00:49:24 +08:00
parent 12594961fe
commit b8b6007b51
4 changed files with 41 additions and 2 deletions
+7 -1
View File
@@ -124,8 +124,14 @@ app.whenReady().then(async () => {
evidence.newSaved = true
// Electron resize and the production sidebar transition settle asynchronously.
win.setSize(760, 800)
await wait(`${panel}.getBoundingClientRect().width > 100`, 'narrow panel layout after resize')
await wait('window.innerWidth < 900', 'narrow viewport after resize')
await run('new Promise(resolve => requestAnimationFrame(() => requestAnimationFrame(resolve)))')
if (await run('document.querySelector(".assistant-sidebar-toggle").getAttribute("aria-expanded") === "false"')) {
await click('Toggle assistant workspace')
}
await wait(`document.querySelector(".assistant-sidebar-toggle").getAttribute("aria-expanded") === "true" && ${panel}.getBoundingClientRect().width > 100`, 'visible narrow panel after resize')
await run(`document.querySelector('#compact-note-append').focus()`)
await wait('document.activeElement?.id === "compact-note-append"', 'narrow append focus')
await key('Escape')
await wait('document.activeElement?.id === "compact-note-search"', 'Escape returns to list and search')
await key('Tab')