Skip to content

Code's popups stay inside its panel; the tour dims the panel around each control - #284

Merged
atyrode merged 12 commits into
mainfrom
panel-layer
Oct 13, 2026
Merged

atyrode merged 12 commits into
mainfrom
panel-layer

Conversation

@atyrode

@atyrode atyrode commented Oct 13, 2026 •

Copy link
Copy Markdown
Owner

What

Code's popups no longer take over the whole Manifold window, and the tutorial becomes a spotlight tour that dims the panel around each control.

One layer inside each Code panel

  • New shared plugins/code/panel-layer.tsx: a PanelLayer context (the panel root), PanelDialog (a non-modal <dialog open> centred in the visible part of the panel over a dim that covers only that panel), holdPanel(panel, keep) (per-element counted inert on everything in the panel but layers, the live region and what keep names), useDeliberate (the question guards: 400 ms settle, 300 ms focus hold for keys, multi-click ignored), keepTab, giveFocusBack, focusBehind.
  • Everything Code showed with showModal() now goes through it: the questions a Launch waits on (DecisionDialog), Shortcuts, Models' import, and the native permission review (Setup, Manage accounts, and the separate accounts panel, whose root now provides the layer). Only the Code panel dims and goes inert; the rest of Manifold is neither covered nor held. Esc takes the way out; a settled press on the dim does too for questions and Shortcuts, never for the import or a review. Focus goes back to what had it, and a sheet a question's fix opens gives it back there in turn. The live region stays out of the hold, so it keeps speaking. Panel roots get isolation: isolate.
  • The old decision host and the tutorial's offer-as-a-question (tutorialOffer, the tour choice, PressDecision) are gone.

The tour

  • Welcome: a card in the middle of the dimmed, inert panel ("Welcome to Code", what Code is in a sentence, Take the tour / Skip), with the question guards; Esc and a settled press on the dim skip.
  • Walk: 8 steps in the order Code is used: the profile's rows with the readout under them, cost and speed, routing, usage, the launch with its machine, Accounts, the Sessions tab, More. The dim's opening (a clip-path cut, 6 px round the lit parts) grows from where the welcome stood to the first control and glides between controls; a 1 px accent rule sits on it; the card comes in beside it as it lands, with progress as blocks (read out with the card as "Step N of M").
  • Safe by construction: during the walk the panel is inert except the lit parts a step offers to try (the profile's words; a tab or Show control that opens Accounts, or routing/usage where the layout keeps them behind one), and only once the opening has landed. So no key, press or assistive tool reaches Launch, More or anything else, and a struck word clicked through the opening only says why (no model check). Opening a tab glides the opening to the pane it shows (look-only) and the walk waits for Next; choosing a word goes on by itself. Focus the hold strands goes to the card's Next; Esc ends the walk from anywhere in the panel. A step whose control is not shown keeps its card in the middle. The end puts focus on More and the dim fades as the opening closes. Reduced motion places everything at once.

Verification

Head-specific evidence for ade745df2a8488cda36b6e288357bba941da4fac:

  • scripts/gate.sh (Bun 1.4.2, two CPUs, exact Manifold 82605419ea9a67198d9ea0dae1257a8fd812ecd8 and OMP pins): exit 0. 461 unit tests pass; type check clean; four bundles packed; disposable native composition; real-browser verifier PASS (618s).
    • One earlier run on the same head failed in the unchanged agent-launch phase with a driver error carrying no verifier frame, while another session's headless Chromium held three CPUs; the immediate rerun passed. The gate on the previous verifier head (9c7856d388) also passed.
  • Independent reviews, head-specific:
    • Questions, holds, focus order, native review and accounts root: pass (39603f133b); the later commits touch only the tour's settle, focus, scrolling and the verifier.
    • Tour: pass (5828a7e616) for the product, then the two scrolling fixes (280c2f71f7, bf29bbda42) read in round 4.
    • Verifier: pass (ade745df2a) after five rounds (coverage, races, measured settle, consumer rules over pins).
  • Real surface in Chromium (disposable lab): the welcome centred in the dimmed panel with Manifold's sidebar untouched; the opening growing from the centre to the profile and gliding between steps; trying a word and the Accounts tab; look-only steps holding presses; Tab/↵ never reaching Launch; Esc from a tried row ending the walk; a charge question, Shortcuts, Models' import and Setup's native review all inside the panel with the panel inert; 360 and 170 px; reduced motion and coarse pointer.

What the verifier states it does not prove: panel keys with focus on the root while a dialog holds the panel (no real input reaches that state), Esc within the welcome's first 400 ms, the struck word's check gate being open, and ← from the panel root.

Closes #283

@atyrode

atyrode commented Oct 13, 2026

Copy link
Copy Markdown
Owner Author

Head-specific evidence for 471a39ee543e2780fcd484c14b526fac34ee520f:

  • scripts/gate.sh (Bun 1.4.2, two CPUs, exact Manifold and OMP pins): exit 0; 461 unit tests; type check clean; four bundles packed; disposable native composition; real-browser verifier PASS (609s).
  • CI on this head: test, plugins / verify and agent-policy pass.
  • Reviews:
    • Product (questions, holds, focus, native reviews, accounts root, tour): ## Verdict: pass (96e507104b); the product is unchanged after it.
    • Verifier: ## Verdict: pass (471a39ee54).
  • What changed after the first green local gates: CI's runner showed that a synthesized wheel over the opening does not natively scroll the panel there, so the "control out of view" check now chooses its window height from the measured layout and brings the panel's scroll region to its end directly before proving the centred fallback. Whether a wheel through the opening scrolls the panel is therefore not asserted; nothing in the docs claims it.

@atyrode
atyrode merged commit 0dea1e1 into main Oct 13, 2026
4 checks passed
@atyrode
atyrode deleted the panel-layer branch October 13, 2026 20:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Code's popups stay inside its panel; the tour spotlights each control

1 participant