From d3ca90afcc56b2d5ce5ae6ad531742788a444dba Mon Sep 17 00:00:00 2001 From: yetone Date: Fri, 16 Oct 2026 03:55:42 +0800 Subject: [PATCH] gui tests: text-size scrolls its control to below the Settings tabs held at the top 8f55c27ad (#2396) holds Settings' tabs at the view's top. "100% picked at the foot of the page" scrolled until the 100% button was within 60px of the view's top, which is now under that head, and the click timed out on "
intercepts pointer events" in both engines (20/2 on origin/main 1a16fc0b5). It stops 60px under the head's foot now, as a reader could still click it. Run: text-size 22/0 (chromium, webkit) at 1a16fc0b5 + this change. --- internal/gui/tests/text-size.test.cjs | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/internal/gui/tests/text-size.test.cjs b/internal/gui/tests/text-size.test.cjs index dc767b644..b78f1517a 100644 --- a/internal/gui/tests/text-size.test.cjs +++ b/internal/gui/tests/text-size.test.cjs @@ -217,10 +217,11 @@ for (const engine of (process.env.BROWSER ? [process.env.BROWSER] : ["chromium", const v = page.locator("#view-settings"); await v.hover(); // down as far as the control is still in sight: to the foot, or the - // control at the view's top + // control just under the view's top, below the tabs held there + // (#2396) as they would cover it for (let i = 0; i < 400; i++) { if (await v.evaluate((v) => v.scrollTop >= v.scrollHeight - v.clientHeight - 1 - || document.querySelector("#textSizeSegs").getBoundingClientRect().top < v.getBoundingClientRect().top + 60)) break; + || document.querySelector("#textSizeSegs").getBoundingClientRect().top < Math.max(v.getBoundingClientRect().top, v.querySelector(":scope > .set-head").getBoundingClientRect().bottom) + 60)) break; await page.mouse.wheel(0, 40); await page.waitForTimeout(20); }