Panes: clicks, selection, tabs, peek and curves that keep to their content; Alt+h j k l between panes

- A click anywhere in a pane that is not text, a row or a link makes it the active pane; a click
  anywhere else, or Esc, clears a selection.
- The page measures where each pane was opened from, so its column stands in that order.
- A crowded column stacks the panes after the one looked at at its foot, a tab each, so every pane
  shows at least its tab; the curve into a tab becomes the tab's line where it meets it (no stub).
- A pane cut off for any reason (covered, too small a share, past the foot) peeks out as tall as its
  text needs, without moving the panes around it; curves are redrawn on peek, on a pane's text
  changing size (ResizeObserver) and every frame while anything animates.
- The curve joins the active pane's title rule too (the heavy rule alone marks it); a source out
  of sight in a pane that still shows is pointed at: dotted, turned at its end toward it; a curve
  leaves from a tab's foot only when its pane is folded to the tab.
- The selection bar sits under a pane's tab, takes the room above or below the words, never covers
  them; a sticky tab's title is centred under the heavy rule; focus is kept clear of the tab.
- Alt+h / Alt+l: the pane opened from (left) / one opened from this one (right); Alt+k / Alt+j
  (Alt+↑ ↓, [ ]): above / below in the column; from a node, a selection or an article; in the pane menu.
- Browser tests (e2e/panes3.spec.ts) with a curve invariant (curveFaults) checked after peeks,
  scrolls, resizes, folds, a drag and an article arriving.

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 22:10:24 -05:00
1 parent 24a048a9f8
commit 0df51493cd
13 files changed
+727 -61

No files matched your search

+7 -6
View File
@@ -171,15 +171,15 @@ test("a click, a Ctrl- and a middle click open beside; a Shift-click in place; a
expect(await trail(page)).toEqual(["Infinispand", "Borrowed from Gwern", kids[0]]);
expect(await focusedTitle(page)).toBe(kids[0]);
await expect(page.locator(".pane.active .pane-head h2")).toHaveText(kids[0]);
// The first pane's rows too: beside, in the next column; and a click on a row already open keeps it.
// The first pane's rows too: beside, in the next column (above, as its row is above); and a click on a row already open keeps it.
await row("Display forms").click();
expect(await columns(page)).toEqual([["Infinispand"], ["Borrowed from Gwern", "Display forms"], kids.slice(0, 3)]);
await expect.poll(() => columns(page)).toEqual([["Infinispand"], ["Display forms", "Borrowed from Gwern"], kids.slice(0, 3)]);
await row("Display forms").click();
expect((await columns(page))[1]).toEqual(["Borrowed from Gwern", "Display forms"]);
expect((await columns(page))[1]).toEqual(["Display forms", "Borrowed from Gwern"]);
// A Shift-click opens in place of the focused one (Display forms), and selects no text on the way.
await row("Editing and regeneration").click({ modifiers: ["Shift"] });
expect(await trail(page)).toEqual(["Infinispand", "Editing and regeneration"]);
expect((await columns(page))[1]).toEqual(["Borrowed from Gwern", "Editing and regeneration"]);
await expect.poll(async () => (await columns(page))[1]).toEqual(["Editing and regeneration", "Borrowed from Gwern"]);
expect(await page.evaluate(() => window.getSelection()?.isCollapsed ?? true)).toBe(true);
});
@@ -197,14 +197,15 @@ test("a link and an article's link open beside by default, in place with Shift;
await keys(page, "h");
await tabTo(page, "lambda calculus");
await keys(page, "Shift+Enter");
expect((await columns(page))[3]).toEqual(["Fixed-point combinator", "“lambda calculus”"]); // a note on the words, with the article beneath
// A note on the words, with the article beneath; above, as its words come first in the text.
await expect.poll(async () => (await columns(page))[3]).toEqual(["“lambda calculus”", "Fixed-point combinator"]);
// In an article: a click opens beside, a Shift-click in place.
const art = pane(page, "Fixed-point combinator");
await art.locator('.wiki-text a[data-wiki="Haskell Curry"]').click();
await art.locator('.wiki-text a[data-wiki="Recursion (computer science)"]').click();
expect((await columns(page))[4]).toEqual(["Haskell Curry", "Recursion (computer science)"]);
await art.locator('.wiki-text a[data-wiki="Lambda calculus"]').first().click({ modifiers: ["Shift"] });
expect((await columns(page))[4]).toEqual(["Haskell Curry", "Lambda calculus"]);
await expect.poll(async () => (await columns(page))[4]).toEqual(["Lambda calculus", "Haskell Curry"]);
// Twenty opens in a row: each a pane of its own, the column stacked, the keys still quick.
await open(page);
await page.evaluate(() => ((globalThis as any).__ie.samples.length = 0));