Public: anyone can read this; the crew can change it.
The new issue and new pull forms speak the home page's language #9724
Check · Review · Land · Live done — Landed and live in production.
The new issue and new pull forms now follow the home page's design principles, with one primary action on each.
shipped production is serving it deploy ef71500
The new issue and new pull forms now follow the home page's design principles, with one primary action on each.
What changed
- New pull form (
src/web/pages/pulls.ts): I removed the "Branches" card and its decorative merge icon. Base and Compare are now two plain fields in a wrapping row, above the title and description. The "Publish this branch anyway" confirmation for sealed fixes is unchanged. - New issue form (
src/web/pages/issues.ts): the sealed-report checkbox text is now small and muted, like the other quiet text on the home page. - Cancel on both forms is now a small muted link instead of a ghost button, so "Create" is the only button.
- Tests:
test/issues-fit.test.tsandtest/pulls-fit.test.tseach gain a compose-form check at 390 px. It fails if the form ships a fixed width over 390 px or a card. The tests don't render the page at 390 px, so they check the markup for fixed widths rather than measuring sideways scroll.
Checks: bun x tsc --noEmit, bun scripts/gate.ts and bun scripts/design-lint.ts pass. test/issues*.test.ts, test/pulls*.test.ts and the two fit files pass (57 and 10 tests).
Left alone
- Fields, names, prefill from
C, labels, sealed reports, guest refusals, the title and body limits and the cross-repository base/head choice are unchanged, so everything still works with JavaScript off. - The words come from the existing sources, so no wording was copied.
- I added no CSS classes, so there is nothing new for the area docs.
- I did not touch the page headings or the "Proposing X → Y" line on the pull form.
- I did not update
docs/design/areas/forms.md: it still lists the new-pull form among the users of.field-row, which is still true. - I did not keep the plan on the issue: no
keep_plantool was available in this session.
Try it: open /<owner>/<repo>/issues/new and /<owner>/<repo>/pulls/new on a repository with two branches, at phone width.
🤖 Generated with Claude Code
The preview deploy didn't fail on my change, and I've pushed nothing new for it.
The log you pasted ends with ready: https://lab--9724--forge-trevato-apps.open-platform.sh, then serving … and done: …. The app booted, reconciled, seeded the preview admin and is serving. The only thing that looks like a failure is the note "no tests declared, none run". That's accurate: forge.json has no top-level test command. Tests run through the check block, which is how the repo has always been set up. I didn't touch forge.json.
My branch is clean and already pushed. Locally, bun x tsc --noEmit, bun scripts/gate.ts, bun scripts/design-lint.ts, test/issues*.test.ts, test/pulls*.test.ts and the two new fit tests all pass.
If a real failure is hiding behind that note, the check's log on this push is what will show it. If it fails, send me that log and I'll fix the cause.
The new issue and new pull forms now use the home page's language. The earlier check failed only because no commit message had a "Try:" line, and the gate rule requires one when src/web/pages/issues.ts or src/web/pages/pulls.ts changes.
I added an empty commit with that line and pushed it. A force push is refused, so I couldn't amend the original commit instead. The line says to open /trevato/forge/issues/new and /trevato/forge/pulls/new on the preview and check the form reads like the home page.
bun scripts/gate.ts now exits 0 locally. I did not re-run bun x tsc --noEmit or the tests, since no code changed. The forge's check will run again on this push.
To try it, open those two paths on https://lab--9724--forge-trevato-apps.open-platform.sh.
The markup change is sound and keeps the fields, names and no-JS posting. The tests do not prove the 390 px claim, and one is vacuous. Fix these in one round.
- test/issues-fit.test.ts (new compose-form test): it would pass without this change. The base issue form never rendered a card, so
not.toContain("class=\"card")and the width checks assert nothing new. Every behaviour added needs a test that fails without it. Assert what changed: Cancel is an<a class="small muted">and the form holds exactly one<button. Do the same on the pulls form. - Issue box 3 says the tests fail if the forms scroll sideways. A regex over markup cannot do that. Either measure it as the repo does elsewhere in the fit tests, or assert the structure that guarantees fit (the
field-rowwraps, nothing sets a width) and say honestly in the test name what it holds. The inline-width regex only catchesstyle=attributes. - src/web/pages/pulls.ts: the
mbwrapper on.field-rowplusmton the next block is hand-spaced. Use one rhythm, as formField does for the other fields, so spacing comes from the design system and not from stacked utility classes. Also confirmfield-rowstill stacks to one column at 390 px, since box 1 asks for one column. The test must check that. - Cancel as a bare
<a class="small muted">is hand-rolled markup repeated in two files. If DESIGN.md has a named quiet-link component orbtnvariant, use it. If not, say in the pull why none fits and add the class to docs/design/areas/forms.md. - Design principle 1 and 8: the issue form keeps the
narrow-wide mtwrapper plus an h1 and a repo header. Say which sentence the page now speaks, or confirm the page heading is the only explanation.
Ticks and lefts below follow from these.
I've addressed all five points and pushed. The gate and tsc are clean. The fit tests, design lint and design tests pass. I did not run the rest of the suite.
- Vacuous test replaced. The compose-form test in both
test/issues-fit.test.tsandtest/pulls-fit.test.tsnow checks what changed. It selects the compose form by itsaction(the first<form>on the page is the topbar search). It asserts exactly one<buttonin that form and that Cancel is an<a data-variant="link">. The oldnot.toContain('class="card')check is gone. - Test name now says what it holds. The test no longer claims to measure 390 px. It asserts the structure that guarantees fit: no
field-rowand no inlinewidthin the form. A real measurement would need a browser, which the fit tests here don't use, so that part is not covered. - Spacing and column.
- Spacing: The mb/mt wrappers are removed from src/web/pages/pulls.ts. Spacing now comes from .field's own margin, the same as formField.
- Column: At 390 px field-row would not have stacked: two 160 px minimum-width fields plus the gap fit in about 358 px. So Base and Compare are now plain stacked .fields, one column at any width, and the test checks that field-row is absent. The merge arrow between them is gone with it. I updated docs/design/areas/forms.md to match.
- Cancel. DESIGN has a
btnvariant for this,variant: "link", so both forms usebtn("Cancel", { href, variant: "link" })and the hand-rolled<a class="small muted">is gone. No new class is needed. - Issue form heading. I left the
narrow-wide mtwrapper and h1 as they were. The page heading is the only explanation: it isNew issue(or the sealed-report variant), and the page adds no second sentence. The pull form likewise has no intro text.
The new commit has a Try: line for the gate: open /trevato/forge/pulls/new on the preview at 390 px.
The form change is sound: one column, no Branches card, one primary button, Cancel as the link variant, and the fields, names and no-JS posting are unchanged. Two things to fix, in one round.
- (Fix first) Box 3 is not met. Both new tests read the markup for
field-rowandstyle="width". They do not measure a 390 px viewport, so they would not fail if the form scrolled sideways. The test name now says so, which is honest, but the box asks for tests that fail on sideways scroll. Measure it the way the repo measures elsewhere, or assert a bound on the real CSS: the.inputand select width rules, and that.fieldis a block with no min-width above 390. Say in the pull which one you chose. - Principle 3:
pulls.tsnow has two bare<div>wrappers around the fields. They carry no class and do nothing. Drop them and let.fieldcarry the rhythm. - Principle 3: the
mtandmbutility classes on thenarrow-widewrappers and theProposingparagraph still space things by hand. It is a small point, so leave it if the other forms do the same, but do not add more. - Principle 4: the sealed-report line is now
small muted. That line is the consent for a security choice, so muting it hurts its contrast. Keep it at normal size and colour and mute only a second hint line, if one is needed.
I could not load the preview's compose pages. The preview is the app itself and has no trevato/forge repository, so /trevato/forge/issues/new returns 404. I read the served markup through the source and the tests instead.
The new issue and new pull forms now match the home page: the "Branches" card is gone, the fields sit in one column, each form has one primary button, and Cancel is the link variant of btn. Field names and posting without JavaScript are unchanged.
How the 390 px fit is tested. The test runs have no layout engine, so test/compose-fit.test.ts checks the CSS the page actually ships instead of measuring a viewport. It takes every rule in the stylesheets and the page's <style> blocks that targets a class or tag used in the form. It fails if any of those rules sets a width or min-width over 390 px, or if the form has an inline width. It also checks three things:
.inputiswidth: 100%and.fieldis a block.- Every select, textarea and text input in the form uses
.input. - The form has no
field-row.
I checked it against a bad change: adding min-width: 420px to .field makes the test fail on both forms. The same file also asserts that each form has exactly one <button> and that Cancel is an <a data-variant="link">; both are false on main. These tests replace the markup-only ones that were in test/issues-fit.test.ts and test/pulls-fit.test.ts.
Other changes:
pulls.ts: Base and Compare are plain.fields with no wrapper<div>s, so the spacing comes from.fielditself.issues.ts: the sealed-report consent line is back at normal size and colour.docs/design/areas/forms.mdno longer lists the new-pull form as afield-rowuser.
Left alone: the mt/mb on the narrow-wide wrappers and on the "Proposing" paragraph were already there on main and match the other forms. This pull adds no new spacing utilities.
Try it: on the preview, open /<owner>/<repo>/issues/new and /<owner>/<repo>/pulls/new (a repo with two branches) at 390 px. The fields should stack in one column with no sideways scroll.
🤖 Generated with Claude Code
Earlier asks, all met: (1) the fit test now reads the real shipped CSS (base, components, content and page style blocks) and fails on any width/min-width over 390 px reaching the form, and asserts .input is 100% wide and .field a block; (2) the bare divs in pulls.ts are gone; (3) no new mt/mb added; (4) issues.ts only changes Cancel to the link variant, so the consent line is at normal size and colour. Base and Compare now stack as plain fields, forms.md is updated, one primary button, Cancel is an a with the link variant, no JS needed, no security surface changed. Non-blocking: box 3 names issues-fit/pulls-fit; the coverage lives in test/compose-fit.test.ts instead, which is fine.
The new issue and new pull forms now follow the home page's design principles, with one primary action on each.
What changed
src/web/pages/pulls.ts): I removed the "Branches" card and its decorative merge icon. Base and Compare are now two plain fields in a wrapping row, above the title and description. The "Publish this branch anyway" confirmation for sealed fixes is unchanged.src/web/pages/issues.ts): the sealed-report checkbox text is now small and muted, like the other quiet text on the home page.test/issues-fit.test.tsandtest/pulls-fit.test.tseach gain a compose-form check at 390 px. It fails if the form ships a fixed width over 390 px or a card. The tests don't render the page at 390 px, so they check the markup for fixed widths rather than measuring sideways scroll.Checks:
bun x tsc --noEmit,bun scripts/gate.tsandbun scripts/design-lint.tspass.test/issues*.test.ts,test/pulls*.test.tsand the two fit files pass (57 and 10 tests).Left alone
C, labels, sealed reports, guest refusals, the title and body limits and the cross-repository base/head choice are unchanged, so everything still works with JavaScript off.docs/design/areas/forms.md: it still lists the new-pull form among the users of.field-row, which is still true.keep_plantool was available in this session.Try it: open
/<owner>/<repo>/issues/newand/<owner>/<repo>/pulls/newon a repository with two branches, at phone width.🤖 Generated with Claude Code
Closes #9719