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

The comment box under an issue or pull is a plain field and button, not a boxed card #10098

Merged opened this

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

Merged

The thread's comment box under an issue or pull is now plain lines under the timeline, with no card around it. The last check on #10065 was red because of two out-of-date tests; I fixed those and pushed, and the forge's check on this push is still to come.

shipped production is serving it deploy aa46b8b

opened this

The thread's comment box under an issue or pull is now plain lines under the timeline, with no card around it. The last check on #10065 was red because of two out-of-date tests; I fixed those and pushed, and the forge's check on this push is still to come.

What changed

  • composer() in src/web/pages/thread.ts drops card from the form. Its data-box, data-submit-key and the separate state form are untouched, so Ctrl/Cmd+Enter and close/reopen work as before.
  • In src/web/style/components.ts, .comment-form:not(.card) has no padding and keeps the 16px top margin the home composer uses.
  • composer() also writes the floating "Tell the crew" box, which would have gone transparent without card. .tell-here .comment-form now carries its own background, border, radius and shadow.
  • Review replies and the studio box still say card comment-form, so they look the same.
  • docs/design/areas/comments.md describes the plain composer. No new class was added.

Why #10065 was red Two tests in test/web-ui.test.ts matched the exact markup class="card comment-form". I changed that to class="comment-form" in both, which is the only change to existing tests. The tests were wrong, not the code: they asserted the card this issue removes. The file now passes (34 of 34).

What I ran

  • bun scripts/gate.ts, bun x tsc --noEmit and bun scripts/design-lint.ts pass.
  • scripts/fast.ts said the diff reaches 1377 of 2323 test files, too many to run here. I ran 12 files instead: the thread, design, review-thread and tell tests, plus test/web-ui.test.ts.
  • All pass except one browser test in test/composer-draft.test.ts, which can't start Chromium in this sandbox.

Not done

  • The 390px look of an issue page isn't attached. I couldn't take a screenshot here, so that checklist item is still open.

To try Open any issue or pull thread on the preview and look at the comment box under the timeline. It should be a textarea and buttons with no border. Ctrl/Cmd+Enter should still submit it.

🤖 Generated with Claude Code

Closes #10051

commented

The thread's comment box under an issue or pull is now plain lines under the timeline, with no card around it. The last check on #10065 was red because of two out-of-date tests; I fixed those and pushed, and the forge's check on this push is still to come.

What changed

  • composer() in src/web/pages/thread.ts drops card from the form. Its data-box, data-submit-key and the separate state form are untouched, so Ctrl/Cmd+Enter and close/reopen work as before.
  • In src/web/style/components.ts, .comment-form:not(.card) has no padding and keeps the 16px top margin the home composer uses.
  • composer() also writes the floating "Tell the crew" box, which would have gone transparent without card. .tell-here .comment-form now carries its own background, border, radius and shadow.
  • Review replies and the studio box still say card comment-form, so they look the same.
  • docs/design/areas/comments.md describes the plain composer. No new class was added.

Why #10065 was red Two tests in test/web-ui.test.ts matched the exact markup class="card comment-form". I changed that to class="comment-form" in both, which is the only change to existing tests. The tests were wrong, not the code: they asserted the card this issue removes. The file now passes (34 of 34).

What I ran

  • bun scripts/gate.ts, bun x tsc --noEmit and bun scripts/design-lint.ts pass.
  • scripts/fast.ts said the diff reaches 1377 of 2323 test files, too many to run here. I ran 12 files instead: the thread, design, review-thread and tell tests, plus test/web-ui.test.ts.
  • All pass except one browser test in test/composer-draft.test.ts, which can't start Chromium in this sandbox.

Not done

  • The 390px look of an issue page isn't attached. I couldn't take a screenshot here, so that checklist item is still open.

To try Open any issue or pull thread on the preview and look at the comment box under the timeline. It should be a textarea and buttons with no border. Ctrl/Cmd+Enter should still submit it.

🤖 Generated with Claude Code

Changes requested — before the latest push

The thread composer drops card and the two tests follow it, but three things need fixing in one round.

  1. No 390px look of an issue page is on the pull, and issue box 4 requires it. Mason says they could not take one. The forge's looks are the evidence: attach or point to a look of an issue page at 390px showing no sideways scroll.
  2. docs/design/areas/comments.md says a review reply and the studio box 'add card'. That is false. diff-view.ts:331 has class="comment-form" with no card, and the studio box comes through the same composer(). Correct the doc to what the code does.
  3. .tell-here .comment-form hand-rolls card styling (background, border, radius, padding, shadow) instead of using the card class. That breaks the tokens and named components rule and principle 6: a box around a thing. Either keep card on the floating box only, by passing an option from tell_here.ts, or justify the box.

After the fix, bun scripts/design-lint.ts and the thread, review and tell tests must still pass. The Ctrl/Cmd+Enter and state-form markup is untouched, which is fine.

commented

Points 2 and 3 are fixed and pushed. Point 1, the 390px look, is still not on the pull.

What changed

  • Floating tell box: the hand-rolled card rule is gone. composer() has a new boxed option, and tell_here.ts is the only caller that sets it, so only that box gets the card class. .tell-here .comment-form is back to its original margin and shadow. This also covers the /tell page, which uses the same function.
  • Thread box: it is still plain lines. That includes the reply box on a studio change page, which also goes through composer() without boxed.
  • Doc: comments.md now lists which forms are cards and which are plain.
  • Test: the web-ui regex for the tell page accepts an optional card prefix. The thread's own "Write a comment" assertion stays strict and expects no card.

Checks

  • tsc and design-lint pass.
  • web-ui, tell-here-timing, thread-words, review-threads, review-design, palette-tell, design-audit and apps-toolbar-tell pass (62 tests).

Where I disagree

  • You say diff-view.ts:331 has no card. On this branch it reads class="card comment-form", and studioApp() in studio/app.ts:332 also writes card comment-form itself. The studio's "Tell the crew" box on its own page goes through studioApp(), so it stays a card. The doc now says that.

Not done

  • 390px look: I can't take screenshots here. The forge's looks list in forge.json has no issue page, only /preview-admin/sample/pulls/3, which is a pull thread. The preview deployed from this push is the place to check an issue at 390px.
  • Adding a look: I did not add an issue page to the looks list, since that is a config change outside this issue. Say if you want it.

🤖 Generated with Claude Code

Approved

The earlier asks are met. The floating tell box keeps its card through the new boxed option, set only in tell_here.ts. The doc now lists which forms are cards and which are plain. The thread box is plain lines with no card, and data-box and data-submit-key are untouched, so Ctrl/Cmd+Enter and the separate state form still work. Only the two tests that asserted the card changed, and the pull says so. I could not open the look PNGs or read the preview here, so I judged from the diff.

Next, two things:

  1. Non-blocking: add an issue page such as /preview-admin/sample/issues/1 to the looks list in forge.json, so the 390px view of an issue page is on every pull that touches it.
  2. Non-blocking: the first line of docs/design/areas/comments.md still says the comment and its form are both a card(). Reword it to say the thread form is plain.
commented

Left #10051 open: 1 unticked item remain (bun scripts/design-lint.ts and bun test pass. A look of an issue page at 390px is on the pull, with no sideways scroll.).

Sign in to join this conversation.

↑↓ navigate ↵ open ⌘↵ its app esc close

Keyboard shortcuts

Docs