Auto picks panes from 900 px wide, a laptop's window too, not 1600

One pane and the stack of earlier ones beside it read well from there. The browser tests start in
the column (playwright.config.ts) where they mean it; a panes test lets the layout follow the window
(helpers.ts autoLayout). New: auto gives panes at 1366 and the column at 820 and 390.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_014yB6q4BHMwptTX3YFtkRab
This commit is contained in:
thalladaandClaude Opus 5.5 committed 2026-11-16 16:31:21 -05:00
1 parent f8d663ebc1
commit 5f6ea8e5c9
13 files changed
+53 -19

No files matched your search

+4 -1
View File
@@ -5,7 +5,7 @@
* the address it would have gone to.
*/
import { expect, test, type Page } from "@playwright/test";
import { command, focusedTitle, jump, keys, seedLinks, selected, settle, state, writeReport, type Sample } from "./helpers";
import { autoLayout, command, focusedTitle, jump, keys, seedLinks, selected, settle, state, writeReport, type Sample } from "./helpers";
/** The panes' titles, left to right: a node's title, or W:article for a Wikipedia pane. */
const trail = (page: Page) =>
@@ -23,12 +23,15 @@ async function tabTo(page: Page, words: string) {
async function column(page: Page, path = "/doc/fixed-points") {
await page.setViewportSize({ width: 1440, height: 900 });
// After wide(), this page's layout follows the window, and 1440 px is wide enough for panes.
if (page.url().startsWith("http")) await page.evaluate(() => localStorage.setItem("ie:settings", JSON.stringify({ ...JSON.parse(localStorage.getItem("ie:settings") ?? "{}"), view: "column" })));
await page.goto(path);
await page.waitForFunction(() => (globalThis as any).__ie?.ready);
await page.evaluate(() => document.fonts.ready);
}
async function wide(page: Page, path = "/doc/fixed-points") {
await page.setViewportSize({ width: 1920, height: 1080 });
await autoLayout(page);
await page.goto(path);
await page.waitForSelector(".strip .pane");
await page.evaluate(() => document.fonts.ready);