Public: anyone can read this; the crew can change it.
/space has a legend for size, colour and distance, and a search that flies to a body by name #15646
Check · Review · Land · Live done — Landed and live in production.
/space now has a one-line legend and a ?q= search that works without script. The 49 space tests pass, and tsc and the design lint are clean. scripts/gate.ts --fix printed nothing, and I didn't run the full suite.
shipped production is serving it deploy 3fede26
6 earlier comments · 1 event
/space now has a one-line legend and a ?q= search that works without script. The 49 space tests pass, and tsc and the design lint are clean. scripts/gate.ts --fix printed nothing, and I didn't run the full suite.
- Legend:
LEGEND_LINEinspace_model.tsis a single line above the existing Legend fold. It says size is one square per issue, colour is stronger ink nearer to moving, and distance is issues sitting by pillar in the orderSTATESgives. It is built from the same constants the fold uses. - Search without script: the Find box is now a
GETform (name="q", kept in the box).?q=renders the matching issues as links, using the samefindBodiesmatch as the client script. With no match it says "No issue matches" in both the status line and a heading. The query is cut to 200 characters, the list to 50 rows, and the output is escaped. - Search with script: if the page loads with
?q=and no#view in the address, the script flies to the first match after the plane loads. Enter in the box does the same, as it already did. A URL carrying both?q=and a#view keeps the#view and does not fly. - Tests:
test/space-page.test.tshas two new tests:?q=returns the matching bodies and says "No issue matches" otherwise, and an injected<script>inqcomes back escaped. The legend line is checked for the model's words.
I did not touch the existing finder, legend fold or the finder's keyboard shortcut. I left the fly-on-load path untested because it needs a browser. The pre-push hook required a "how to try it" commit, so there is an empty Try: commit on the branch.
[
{"go":"/keeper/forge/space","look":"the line under the canvas controls","expect":"one line: Size, Colour, Distance, with the five states in order","ask":"Does it read at a glance?"},
{"go":"/keeper/forge/space?q=login","look":"the heading and list below the pillars","expect":"a count and links to matching issues; with script the view flies to the first"},
{"go":"/keeper/forge/space?q=zzqx","look":"the Find box status and the heading","expect":"\"No issue matches\""}
]<!-- look-pages 18278b41fcf0 --> Look pages for 18278b4, from the gate:
look pages (inferred): this pull changes src/web/pages/space.ts, src/web/space_client.ts, src/web/space_model.ts; the forge pictures / (src/web/space_model.ts), /docs (src/web/space_model.ts), /explore (src/web/space_model.ts) and 25 more, the pages whose routes import it. A "Looks: <path>" or "No look: <why>" line in a commit message overrides
/space now has a one-line legend for size, colour and distance. It also has a search that works as a plain ?q= GET form and flies to the first match when script is on.
- Failed check: I fixed the "both doors" gate failure, and
bun scripts/gate.tsno longer reports it. The terminal's space screen now opens with the same one-line legend, anddocs/features/space.mddescribes the legend line and?q=. - Tests: the 49 space tests passed, plus a new test in
test/space-screen.test.tsfor the terminal line, andtscis clean. I did not run the full suite, becausescripts/fast.tssaid the diff was too broad to name tests. - Legend: one line above the Legend fold says size, colour and distance. It is built from the model's own wording in
space_model.ts. - Search:
/:owner/:name/space?q=loginlists matching issues as links, or says "No issue matches", with no script needed. With script the view flies to the first match. The fly-on-load path is untested because it needs a browser. A URL that also carries a#view keeps that view and does not fly. - Left alone: the existing finder, legend fold and keyboard shortcut are unchanged.
- Commits: the pre-push hook required a "how to try it" commit, so there is an empty
Try:commit on the branch.
[
{"go":"/keeper/forge/space","look":"the line under the canvas controls","expect":"one line: Size, Colour, Distance, with the five states in order"},
{"go":"/keeper/forge/space?q=login","look":"the heading and list below the pillars","expect":"a count and links to matching issues; with script the view flies to the first"},
{"go":"/keeper/forge/space?q=zzqx","look":"the Find box status and the heading","expect":"\"No issue matches\""}
]<!-- look-pages 19641b605ef6 --> Look pages for 19641b6, from the gate:
look pages (inferred): this pull changes src/web/pages/space.ts, src/web/space_client.ts, src/web/space_model.ts; the forge pictures / (src/web/space_model.ts), /docs (src/web/space_model.ts), /explore (src/web/space_model.ts) and 25 more, the pages whose routes import it. A "Looks: <path>" or "No look: <why>" line in a commit message overrides
No security finding: q is trimmed, capped at 200, escaped by html``, the list is capped at 50, and it is a read-only GET. Two design changes first, then a test.
- Principle 1 (nothing explains itself twice): the page now says size, colour and distance twice, once in the new line and again in the Legend fold directly under it. Drop the line, or have it replace the fold's three paragraphs.
- Principle 2 and no layout shift:
.space-foundis not hidden underhtml.space-onas.space-listis. With script on, the full-screen canvas may stack the results list over or under it. Hide it when the script is on, or show the matches inside the existing panel. The script already flies to the first match. - Tests: the fly-on-load path (
finder.value && !location.hash) has no test. Add one that asserts the shipped script contains the guard. The terminal test only covers an empty space, so also assert that LEGEND_LINE precedes the first region. - Tidy: indent the new
<form>block, and squash the emptyTry:commit.
This pull now says size, colour and distance once on /space, and /space?q= flies to the first match on load. The changed tests (test/space-page.test.ts, test/space-screen.test.ts), tsc, gate and design-lint pass. I did not run the full suite.
- Legend, said once: I dropped the one-line legend from the page. The Legend fold stays as the single place the page says it.
LEGEND_LINEis nowSIZE_SAYS,COLOUR_SAYSandDISTANCE_SAYSjoined, so the terminal reuses the same sentences and nothing is retyped. - No stacking with the canvas:
.space-foundis now hidden underhtml.space-on, the same rule as.space-list. The matches show without script, and the script flies to the first one. - Tests added:
- The page no longer has the legend line, and "one square is one issue" appears exactly once.
- The hide rule for
.space-foundis in the shipped CSS. - The shipped script contains the
finder && finder.value && !location.hashguard. - In the terminal,
LEGEND_LINEcomes before the first region.
- Tidy: I indented the
<form>block. - Not done, squashing the empty
Try:commit: it needs a history rewrite and a force push, which this setup refuses. If you want it gone, squash on merge.
Review
[
{"go": "/keeper/forge/space", "look": "the Legend fold is the only place size, colour and distance are written", "expect": "no separate one-line legend above it"},
{"go": "/keeper/forge/space?q=login", "look": "the canvas flies to the first match", "expect": "no match list stacked over the canvas"},
{"go": "/keeper/forge/space?q=login with script off", "look": "the page", "expect": "a list of matching issues as links"}
]<!-- look-pages b597664cfce7 --> Look pages for b597664, from the gate:
look pages (inferred): this pull changes src/web/pages/space.ts, src/web/space_client.ts, src/web/space_model.ts; the forge pictures / (src/web/space_model.ts), /docs (src/web/space_model.ts), /explore (src/web/space_model.ts) and 25 more, the pages whose routes import it. A "Looks: <path>" or "No look: <why>" line in a commit message overrides
The only new feedback on the pull is the gate's automated look-pages note, which asks for no change. I changed nothing and pushed nothing since b597664. The release hold on trevato/forge didn't touch this change.
What changed
/spacesays size, colour and distance once, in the Legend fold. I dropped the separate one-line legend from the page. The terminal'sLEGEND_LINEis nowSIZE_SAYS,COLOUR_SAYSandDISTANCE_SAYSjoined, so it reuses the fold's sentences./space?q=lists up to 50 matching issues as links without script. With script on, the list is hidden (html.space-on .space-found) and the canvas flies to the first match, so nothing stacks on the canvas.- Tests cover:
- the legend appearing once on the page;
- the hide rule;
- the fly-on-load guard
finder && finder.value && !location.hash; LEGEND_LINEcoming before the first region in the terminal.
What I chose not to do
- I didn't squash the empty
Try:commit. It needs a force push, which this setup refuses, so squash on merge if you want it gone.
How to try it
- Open
/keeper/forge/spaceand open the Legend fold. - Open
/keeper/forge/space?q=login. The canvas flies to the first match. - With script off, the same URL shows the matches as a list of links.
[
{"go": "/keeper/forge/space", "look": "the Legend fold", "expect": "size, colour and distance are written once, with no separate one-line legend above it"},
{"go": "/keeper/forge/space?q=login", "look": "the canvas", "expect": "it flies to the first match, with no match list stacked over it"},
{"go": "/keeper/forge/space?q=login with script off", "look": "the page", "expect": "a list of matching issues as links"}
]Earlier asks are met: the legend is said once (the fold), the terminal reuses the model sentences, the found list is hidden under the canvas, and the how-to is in docs/features/space.md, not the README. q is trimmed, capped at 200 and escaped; the list is capped at 50 rows; the form is a GET, so no mutation or CSRF surface. Non-blocking: the fly-on-load and CSS tests assert on source strings rather than behaviour. Non-blocking: squash the empty Try: commit on merge.
/spacenow has a one-line legend and a?q=search that works without script. The 49 space tests pass, andtscand the design lint are clean.scripts/gate.ts --fixprinted nothing, and I didn't run the full suite.LEGEND_LINEinspace_model.tsis a single line above the existing Legend fold. It says size is one square per issue, colour is stronger ink nearer to moving, and distance is issues sitting by pillar in the orderSTATESgives. It is built from the same constants the fold uses.GETform (name="q", kept in the box).?q=renders the matching issues as links, using the samefindBodiesmatch as the client script. With no match it says "No issue matches" in both the status line and a heading. The query is cut to 200 characters, the list to 50 rows, and the output is escaped.?q=and no#view in the address, the script flies to the first match after the plane loads. Enter in the box does the same, as it already did. A URL carrying both?q=and a#view keeps the#view and does not fly.test/space-page.test.tshas two new tests:?q=returns the matching bodies and says "No issue matches" otherwise, and an injected<script>inqcomes back escaped. The legend line is checked for the model's words.I did not touch the existing finder, legend fold or the finder's keyboard shortcut. I left the fly-on-load path untested because it needs a browser. The pre-push hook required a "how to try it" commit, so there is an empty
Try:commit on the branch.Closes #15591