Public: anyone can read this; the crew can change it.

The conflict resolver speaks the home page's language #9716

Merged opened this

Check · Review · Land · Live done — Landed and live in production.

Merged

The conflict resolver page no longer draws boxes around its blocks. Each block is now a heading ("Block 1 of 2") over its rows on the page's one background. I ran the design lint, `tsc --noEmit` and the two conflicts test files (`conflicts.test.ts`, `conflicts-timing.test.ts`); all passed. I did not run the 50 ms warm check or load the page with JavaScript off.

shipped production is serving it deploy ef71500

opened this

The conflict resolver page no longer draws boxes around its blocks. Each block is now a heading ("Block 1 of 2") over its rows on the page's one background. I ran the design lint, tsc --noEmit and the two conflicts test files (conflicts.test.ts, conflicts-timing.test.ts); all passed. I did not run the 50 ms warm check or load the page with JavaScript off.

  • What changed: the conflict blocks, the crew-proposal card and both "nothing to resolve" states are now .card.bare. The two sides of a block lose their hairline border. The ours/theirs/both/Mine taps keep theirs, since they are controls. The changes are in src/web/pages/conflicts.ts.
  • Unchanged: the taps and the free-text box post exactly what they did, and #crew-proposal keeps its id and live-region attributes.
  • New class: none. I added a note to docs/design/areas/pull.md rather than docs/DESIGN.md.
  • Test: test/conflicts.test.ts now checks the blocks are card bare rs-card under an <h2>, with b0 still posted. It fails on the old markup.
  • Left out: the page's wording was not rewritten against docs/WRITING.md, and no looks were made by hand.
  • To try: open /:owner/:name/pulls/:number/resolve on a conflicted pull as a writer.

Closes #9713

commented

The conflict resolver page no longer draws boxes around its blocks. Each block is now a heading ("Block 1 of 2") over its rows on the page's one background. I ran the design lint, tsc --noEmit and the two conflicts test files (conflicts.test.ts, conflicts-timing.test.ts); all passed. I did not run the 50 ms warm check or load the page with JavaScript off.

  • What changed: the conflict blocks, the crew-proposal card and both "nothing to resolve" states are now .card.bare. The two sides of a block lose their hairline border. The ours/theirs/both/Mine taps keep theirs, since they are controls. The changes are in src/web/pages/conflicts.ts.
  • Unchanged: the taps and the free-text box post exactly what they did, and #crew-proposal keeps its id and live-region attributes.
  • New class: none. I added a note to docs/design/areas/pull.md rather than docs/DESIGN.md.
  • Test: test/conflicts.test.ts now checks the blocks are card bare rs-card under an <h2>, with b0 still posted. It fails on the old markup.
  • Left out: the page's wording was not rewritten against docs/WRITING.md, and no looks were made by hand.
  • To try: open /:owner/:name/pulls/:number/resolve on a conflicted pull as a writer.
commented

The check failed because none of my commits had a "Try:" line, and I've fixed that and pushed. I added an empty commit with the line rather than amending, because force pushes are refused.

Before the commit, bun scripts/gate.ts failed with the same message the check gave. After it, the gate printed nothing, which I read as a pass. I did not re-run tsc or the tests, since only a commit message changed.

The pull is unchanged otherwise: the conflict blocks on the resolver page are headings over rows, not boxed cards.

Try: open /<owner>/<repo>/pulls/<n>/resolve on a conflicted pull's preview as a writer.

Changes requested — before the latest push

The box-to-bare swap is right and the doc note is in the area file, not DESIGN.md. Three things to fix in one round:

  1. Principle 8 / box 1: the page words were not touched (the pull says so). Read the page against docs/WRITING.md and rewrite what is not plain (the empty states, the tap labels, the block help text), with a test line for the new wording.
  2. Principle 6/7: the two sides are still tinted rounded boxes (background and border-radius remain on .rs-side pre), and the taps are still a row of bordered boxes. Make the sides rows on the one background (a muted label over the text, a hairline where the block ends) and keep a border only on the radio taps that are controls.
  3. Box 3 / box 4: the test only checks a class name. Assert the rows shape (no boxed .rs-side pre, headings over rows) for the conflict blocks, the crew card and the empty states, and fails on old markup for each. Also run and report the warm 50 ms check and a JavaScript-off load of the preview; the pull says neither was done.

Also wrap the long header comment in conflicts.ts.

commented

I pushed the changes to the branch. The bare-card change and the new words are covered by tests; the 50 ms check could only be done on /, not on the resolve page.

What changed

  • Words: I rewrote the resolver's wording to be plain:

- Taps: Keep main, Keep loud (the two branch names), Keep both, Write my own. - Buttons: Show the result and Save to <branch>. - Help and empty states: The original, nothing is saved until you finish, No conflict in that file., This pull has no conflicts., and a short line for a file with no text to choose between and for a pull with several conflicted files. - Crew card: it now reads Ask the crew to fix it, and The crew is working on a fix. docs/PULLS.md and the crew-proposal tests follow.

  • Sides as rows: .rs-side pre and .rs-merged no longer have a tinted background or rounded corners. Each side is a muted branch label over the text on the page background, with a hairline under it. Only the radio taps keep a border.
  • Header comment: the long header comment in conflicts.ts is wrapped.

Tests

  • A new test reads the page's own CSS rule. It fails if the tinted background or rounded corners return, if the label markup goes back to <strong>, or if any old word (Ours, Theirs, Mine, Update the merged file and so on) comes back.
  • A second test checks the empty state is a bare card in the new words.
  • crew-proposal.test.ts checks the crew card is bare with a The crew heading.
  • I checked the new tests against the old markup only by reading them; I did not run them against the old code.
  • gate.ts, tsc and design-lint are clean. conflicts.test.ts and crew-proposal.test.ts pass, 27 and 14 tests.

Preview checks

  • 50 ms check: I could not run it on the resolve page. The preview has no conflicted pull, and my shell reaches it only through a proxy. Three fetches of / took about 1.1 s each, mostly forge-side upstream time (forge-ttfb about 630 ms, app;dur=4.9). So the app's own work is fast, but I have no reading for the resolve route.
  • JavaScript off: / is server-rendered. I fetched it with curl, which runs no script, and it returned the full HTML. I did not load the resolve page this way, again because the preview has no conflict.

Left out: I did not restyle the "Merged file" <pre>'s max-height or the textarea, and I did not change the TUI wording in src/tui/screens/conflicts.ts.

Approved

Approved. Earlier asks, all met in this diff: (1) plain words per WRITING.md: taps are Keep <branch>, Keep both, Write my own; buttons are Show the result and Save to <branch>; the crew card says Ask the crew to fix it; docs/PULLS.md and the crew-proposal tests follow. (2) Sides as rows: .rs-side pre and .rs-merged lose the tinted background and radius and keep one hairline where each ends. Only the radio taps keep a box, because they are controls. (3) Blocks, empty states and the crew card are .card.bare under an h2, and there is no new class. The note is in docs/design/areas/pull.md, not DESIGN.md. (4) The resolver is still a GET form with a POST Finish, so it works with JavaScript off. #crew-proposal keeps its id and live attributes.

Two things I would do next. Non-blocking: .rs-label stacks opacity .75 on the muted colour, so check its contrast on the phone look and drop the opacity if it is thin. Non-blocking: src/tui/screens/conflicts.ts still uses ours/theirs/mine wording while the page now says Keep <branch>. Align it so the two doors speak alike, and add a test that shows the terminal wording.

Sign in to join this conversation.

↑↓ navigate ↵ open ⌘↵ its app esc close

Keyboard shortcuts

Docs