fix: approval windows open as wide as the page (closes #518)
check / check (push) Waiting to run
e2e / e2e-chrome (push) Waiting to run
e2e / e2e-firefox (push) Waiting to run

The approval window was opened 360 pixels wide while the page is 396, so
it scrolled sideways and cut off the Reject button. It now opens at 396.
The browser counts the window's frame in that width, and a tall screen
gives some of it to a vertical scrollbar, so once the approval's screen
is up the page widens its own window by however far it would scroll
sideways, times the page's zoom. The toolbar popup's window is left
alone. The Firefox suite checks that the sign prompt does not scroll
sideways; the Chrome suite cannot, as its approval windows open at
1280x720 whatever size is asked. README's Visual Style line now gives
the page's real width.

Model: opus-5-5
This commit is contained in:
2026-10-14 19:34:18 +00:00
parent f4551dcb67
commit 7d841b39f6
8 changed files with 174 additions and 10 deletions
+11
View File
@@ -640,6 +640,17 @@ step(
await d.switchToWindow(popup);
await d.waitVisible("#view-approve-sign");
// The window is opened as wide as the page, and widened once the
// screen is up if it still scrolls sideways
// (https://git.eeqj.de/sneak/AutistMask/issues/518). This suite is
// where that is checked: the Chrome suite's approval windows open at
// 1280x720 whatever width the extension asks for.
await d.waitFor(
"the sign prompt to fit its window without scrolling sideways",
"return document.documentElement.scrollWidth <=" +
" document.documentElement.clientWidth;",
);
const screen = await d.execute(
`return {
origin: document.getElementById("approve-sign-origin").textContent,