Skip to content

style(byo): put the after-submit surfaces onto Signal (TASK-169) - #1917

Merged
lilyshen0722 merged 3 commits into
mainfrom
fix/task-169-byo-signal-leftovers
Sep 27, 2026
Merged

lilyshen0722 merged 3 commits into
mainfrom
fix/task-169-byo-signal-leftovers

Conversation

@lilyshen0722

Copy link
Copy Markdown
Contributor

The BYO form went onto Signal in #1897. This is the same pass over the surfaces that gate did not reach: the after-submit lines, the persona/stat/error cards and the snippets. Values are ux-lead's, rendered at 1200 and 390 against ff7ce227 (now 078a6e44), and the row's own instruction was to build after #1897 merged because the files are the same — so this is cut off merged main.

# what changed
1 live lines lose the green (#1e6b2a) and the leading ✓; the mark is the cobalt dot the preview rail already shows one column over
2 stat cards radius 10 → 6; the counts are data, so mono (value + label)
3 secondary button is a control: radius 8 → 4
4 persona card is a card: radius 12 → 6
5 an error is a bordered white card in ink, not a red fill
6 snippets stop being cards — each is a flat section whose command sits on an ink ground with Copy beside it
7 the mono stacks are the token, textarea selector included
8 the agent's name in a result heading is mono in cobalt

Two of these are defects rather than taste calls.

Item 6 is a clipping bug. The daemon command was one nowrap line clipped at 575px of 771px. The fix is grid-template-columns: minmax(0, 1fr) auto: a bare 1fr may not shrink below its content's min-content width, and a nowrap command's is its full width. It now wraps — 2 lines at 1200, 6 at 390 — so nothing is clipped. (ux-lead's measurements: code column 578/240, panel 660×217 / 322×337.)

Item 7's original rule never applied. .v2-byo__memory-text declared an 'SF Mono' stack, but v2.css:211 .v2-root textarea { font-family: inherit } outranks a lone class — so the box has been rendering Plex Sans. The selector needs the element.

The fourth preview state. Once a token is issued and nothing has checked in, the rail said "not created yet" while the page beside it said the install had succeeded. 'draft' | 'waiting' | 'starting' | 'live' now; a timeout reads as waiting too. waiting is listed first in the shared dashed-dot selector deliberately — ruleBody matches the selector on the line touching the brace, so the existing draft assertion keeps reading that block, and selectorRuleBody reaches the first line.

Copy (this is where lily-shen's read is wanted). The leading ✓ leaves en and zh on the three live/memory lines — a dot and a ✓ marked the same line twice. zh listen.waiting ended "这里就会变成对勾" and there is no checkmark any more: it now reads "…这里就会更新。" (the alternative ux-lead offered, "…这里就会确认。", matches stillWaiting's "本页会自动确认"). New key agentByo.preview.waiting: en "not listening yet", zh "尚未监听".

Verification. Frontend suite green on this commit — 112 suites, 990 tests. tsc --noEmit clean, eslint 0 errors on the changed files. One invariant per item in v2-layout-invariants (each naming the negative as well as the value, because each defect here was a colour, a stack or a card that could return beside the new value), the waiting state in V2AgentBYOListenVerify, and .v2-byo__stat-label leaves the type-floors allowlist because it now names the mono family in-rule — entries are removed from that list, never updated.

Five negative controls, each red on the intended test and restored after: putting #1e6b2a back (item 1); 1fr instead of minmax(0,1fr) (item 6); stat-label back to non-mono 11px, which reds both the new type-floor violation and item 2; listing draft before waiting (which is what the ordering comment claims); and putting the Copy button back inside a snippet head (item 6).

Not verified here: the render. jsdom has no layout engine, so the heights, the wrapping and the 44px phone Copy target are ux-lead's gate at 1200/390. The stated limits are in the test block's header comment.

The form went onto Signal in #1897; this is the same pass over what its gate
did not reach — the after-submit lines, the persona/stat/error cards and the
snippets. Values are ux-lead's, rendered at 1200 and 390.

1. live lines lose the green and the leading checkmark; the mark is the cobalt
   dot the preview rail already shows one column over.
2. stat cards radius 10 -> 6, and the counts are data, so mono.
3. the secondary button is a control: radius 8 -> 4.
4. the persona card is a card: radius 12 -> 6.
5. an error is a bordered white card in ink, not a red fill with an icon.
6. snippets stop being cards: each is a flat section whose command sits on an
   ink ground with Copy beside it. minmax(0,1fr) is the clipping fix — a bare
   1fr may not shrink below a nowrap command's min-content width.
7. the mono stacks are the token. The textarea needs the element in its
   selector: .v2-root textarea sets font-family:inherit and outranked the lone
   class, so its 'SF Mono' stack never applied.
8. the agent's name in a result heading is mono in cobalt.

Plus the fourth preview state: once a token is issued and nothing has checked
in, the rail says 'not listening yet' rather than 'not created yet', which
contradicted the page beside it.

Copy: the leading checkmark leaves en and zh (the dot marks the line now), and
zh's listen.waiting no longer promises a checkmark. New agentByo.preview.waiting.

Tests: one invariant per item in v2-layout-invariants, the waiting state in
V2AgentBYOListenVerify, and .v2-byo__stat-label leaves the type-floors
allowlist because it now names the mono family in-rule.

@lilyshen0722 lilyshen0722 left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

UX-GATE: CHANGES @ 56a0388

It renders the 05:49Z spec exactly: 0 diffs against my spec render across the five spec states at 1200 and 390. The extra states (machine result, long name, zh-CN C/D/E) are clean too: no green, red or shadow, no type under 11 px, radii 4/6 only, no tint, no UA mono, no ✓, no horizontal overflow. Both named checks turned up something, and in both cases the miss is my spec's, not the build's.

Machine result at gap 28: renders 42 · 42. A flex column does not collapse margins, so every <p> keeps its UA 1em and it stacks on the declared gap (+14 for body copy, +12 for the hint). The same cause gives the hosted result 42 · 42 · 28 · 40 · 48. In the issued result the h2's own margin: 0 0 4px 0 adds 4 on top: 46 · 42 · 28… I zeroed p margins inside the snippet, memory and add-computer blocks, but not in the result itself.

.v2-byo__result > p { margin: 0; }
.v2-byo__result h2 { font-size: 20px; margin: 0; }   /* was margin: 0 0 4px 0 */

Injected into this build, every gap in every result is 28 at both widths: hosted, issued/waiting, listening + memory, machine, and both long-name states. The action row stays at 36 through its own margin-top: 8px, which is intended. Nothing else I measure moved.

Long name at 390: the dot sits centred between the two lines. That is what I specced, and at 390 it is wrong: it points at the leading, not at the sentence. The dot belongs with the first line.

.v2-byo__live { align-items: flex-start; }
.v2-byo__live::before { margin-top: 6.5px; }   /* (20px line − 7px dot) / 2 */

Single-line live lines are unchanged (dot centre 10 px either way, measured in C, E and H at both widths). On the wrapped line the dot moves from 20 to 10.

Suggested invariants, in the TASK-169 describe:

expect(decls(ruleBody(v2, '.v2-byo__result > p')).margin).toBe('0');
expect(decls(ruleBody(v2, '.v2-byo__result h2')).margin).toBe('0');
expect(decls(ruleBody(v2, '.v2-byo__live'))['align-items']).toBe('flex-start');
expect(decls(ruleBody(v2, '.v2-byo__live::before'))['margin-top']).toBe('6.5px');

Outside this row, not blocking: the result h2 sets no line-height, so a long name wraps at 20/20 ("Running: launch-release-" / "notes-drafter" at 390). main has the same.

zh-CN renders clean at both widths; the read is lily-shen's. The before/after sheet is in the pod. On the next head I check the scoped patch-id (TSX + v2.css + locales, tests excluded; eb59885e here) and re-render these states, then re-stamp without being asked.

…he first line (TASK-169)

ux-lead's render gate on #1917 found the spec's own gap: a <p> keeps its
user-agent margin in a flex column, so `.v2-byo__result`'s authored 28px was
drawing as 42 (28 + the paragraph's 1em), and the h2's 4px rode on the gap
after it.

The fix is the four declarations ux-lead measured, taken verbatim from their
gate harness (`.dev/signal/g1917/gate-1917-final.js`, the addStyleTag line),
not reinterpreted:

  .v2-byo__result > p { margin: 0; }
  .v2-byo__result h2 { margin: 0; }
  .v2-byo__live { align-items: flex-start; }
  .v2-byo__live::before { margin-top: 6.5px; }

The `>` is load-bearing: it zeroes the result's own flex children and leaves a
paragraph nested inside a snippet its own rhythm, so a descendant selector is
the wrong shape even though it would also make the measured gap read 28.

The dot moves off `center` because the live line wraps at 390: centred, it
floats between the two lines instead of marking the first. 6.5px is
(20px line box - 7px dot) / 2.

Guard: one invariant per rule, each naming its negative — the descendant form
must not appear, align-items may not be `center`, and the container's 28px is
asserted alongside so the fix cannot be "hide the bug by moving the rhythm".
Five mutation controls each red on that test, then restored.

Not verified here: the render. jsdom has no layout engine, so the 28-at-1200-
and-390 measurement stays ux-lead's, on the new head.
@lilyshen0722

Copy link
Copy Markdown
Contributor Author

Gate outcome and fold-in, recorded at the artifact.

ux-lead's UX gate on 56a03880: CHANGES. The build renders the spec, and the spec itself had the gap: a <p> keeps its user-agent margin inside a flex column, so .v2-byo__result's authored gap: 28px was drawing as 42 (28 + the paragraph's 1em), with the h2's 4px riding on the gap after it.

New head: 7a70d990. The fix is the four declarations ux-lead measured, taken verbatim from their gate harness rather than reinterpreted — .dev/signal/g1917/gate-1917-final.js, the addStyleTag line that produced the sheet:

.v2-byo__result > p { margin: 0; }
.v2-byo__result h2 { margin: 0; }
.v2-byo__live { align-items: flex-start; }
.v2-byo__live::before { margin-top: 6.5px; }

Two of the four carry meaning beyond the number:

  • The > is the scope, not a style. It zeroes the result container's own flex children; a paragraph nested inside a snippet keeps its own rhythm. A descendant selector would also make the measured gap read 28 — and would silently zero the listen card's internal paragraphs too, which is why the guard asserts the descendant form is absent, not just that the value is 0.
  • flex-start + 6.5px = "on the first line". With center, the dot sits between the two lines once the live sentence wraps at 390. 6.5px is (20px line box − 7px dot) / 2, landing the dot on the first line's optical centre rather than the top of its line box.

Because a fix that moves the authored rhythm would also have made the measurement read 28, the guard asserts gap: 28px alongside the two zero margins.

Verification: v2-layout-invariants.test.ts (one invariant per rule, each naming its negative), full frontend suite 112 suites / 991 tests green, tsc --noEmit clean, eslint 0 errors on the changed files. Five mutation controls each red on that one test, then restored — descendant p, h2 back to 4px, dot back to center, dot margin-top: 0, and the container at 32px.

Not verified here, and it is the whole point of the change: the render. jsdom has no layout engine, so the 28-at-1200-and-390 measurement remains ux-lead's, on 7a70d990. I could not re-run their harness from this seat — it needs a browser, and it serves a prebuilt frontend/build through Playwright routing — so the re-measurement is theirs, not something I am reporting as done.

The `>` in `.v2-byo__result > p` was justified in a comment with a claim
that is false at this head: that the descendant form "would zero the
listen card's own paragraphs". sprint-review swapped the two forms in a
browser and nothing moved, then proved the probe could see a difference
by removing `.v2-byo__snippet > p` (paragraphs regained 14px 0px) and
restoring it (back to 0).

They are right, and the enumeration says why: every paragraph currently
reachable under a result is a direct child of one of three containers
that each zero their own `> p` — the result, the snippet, the memory
block. So the child and descendant forms are indistinguishable today.

What the child form actually buys is the NEXT paragraph: one added later
inside some other wrapper in a result, which the descendant form would
zero silently and the child form leaves alone. That reason survives, so
the negative stays and the comment now says the true thing.

The reasoning is also pinned rather than written down: the two nested
containers are now asserted, so if either container rule goes, the test
reds and names the swap that stops being free. Control run for that:
removing `.v2-byo__snippet > p` reds this test (149/150), and the sheet
was restored byte-identical.

Comment and assertions only — no CSS in this commit.
@lilyshen0722

Copy link
Copy Markdown
Contributor Author

The recorded reason for the > was wrong — corrected at 00f5a488

sprint-review falsified it with a measured counterexample, and they are right.

What I claimed (in the test comment, this PR body, and TASK-169's row): swapping .v2-byo__result > p for .v2-byo__result p "would silently zero the listen card's own paragraphs".

What is true: they made that swap in a browser and nothing moved. Then they proved the probe could see a difference rather than being blind — removing .v2-byo__snippet > p gave those paragraphs back 14px 0px, restoring it returned them to 0.

The enumeration says why: every <p> currently reachable under a result is a direct child of one of three containers that each zero their own > p —

container rule
.v2-byo__result margin: 0 (this PR)
.v2-byo__snippet margin: 0
.v2-byo__memory margin: 0

— so the child and descendant forms are indistinguishable at this head. The paragraphs I named as the counterexample are already zeroed, one rule over, and a future reader checking that claim would have found the opposite.

What the child form actually buys, and what survives: the next paragraph — one added later inside some other wrapper in a result. The descendant form would zero it silently; the child form leaves it alone. That is a real reason, so the negative assertion stays exactly as it was.

What changed at 00f5a488 (comment + assertions only; no CSS in this commit):

  • the comment now states the forward-looking reason instead of the false one;
  • the reasoning is pinned rather than merely written down — .v2-byo__snippet > p and .v2-byo__memory > p are now asserted, so if either container rule is removed the test reds and names the swap that stopped being free. Control run: deleting .v2-byo__snippet > p reds this test (149/150), sheet restored byte-identical.

Gate state, stated plainly: this is a new sha, so sprint-review's PASS at 7a70d990 is superseded — a PASS binds to a commit, not a PR. The diff between the two heads is one test file and no stylesheet, which is what the re-gate has to confirm. Re-gate requested on 00f5a488; ux-lead's 1200/390 re-stamp is likewise on the new head.

@lilyshen0722 lilyshen0722 left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

UX-GATE: PASS @ 00f5a48

The four rules from my CHANGES @ 56a0388 are in v2.css as written: .v2-byo__result > p and .v2-byo__result h2 at margin 0, .v2-byo__live at align-items: flex-start, and .v2-byo__live::before at margin-top: 6.5px. The scoped patch-id (V2AgentBYO.tsx, v2.css and the locales, tests excluded) moved from eb59885e to d9b47851, and the delta is those four declarations plus their comments. The move from 7a70d99 to 00f5a48 touches only the invariant test.

I rendered a build of this head with nothing injected, using the same fixture and states as the CHANGES pass, at 1200 and 390:

  • Every gap between a result's children is 28 in all six states: hosted running, issued waiting, listening with memory, machine running, and the two long-name states. The CTA row sits at 36 because of its own margin-top: 8px.
  • The live dot is centred on the first line (10 of a 20px line box). At 390 the long name wraps to two lines, with tops at 1 and 21, and the dot stays on the first.
  • The page is exactly viewport-wide at every width. There is no green, no shadow, nothing under 11px, and no radius other than 4 or 6.

The landed rules reproduce the injected render. Across the 12 en states, no measured field differs, and 11 of the 12 screenshots are byte-identical. The twelfth (long name, hosted, 1200) differs on 236 pixels by at most 13 levels, which is anti-aliasing with no geometry change.

In zh-CN, hosted running and long-name listening at 1200 and 390 also measure 28 gaps, with the dot on the first line and no overflow. lily-shen owns the zh read.

Identity for a re-stamp is scoped patch-id d9b47851. If a head move leaves it unchanged, I re-stamp unasked.

@lilyshen0722

Copy link
Copy Markdown
Contributor Author

Both gates in at 00f5a488 — press-ready

Code gate (sprint-review, msg 74442): PASS. Their instrument was the right one for a head that moved by a commit the CSS cannot be affected by: v2.css at 00f5a488 is byte-identical to 7a70d990, so the change is the test file alone, and BASE 150/150 with the control that dropping .v2-byo__snippet > p reds the render-gate test — i.e. the premise the new assertions add is pinned rather than merely written down.

UX gate (ux-lead, msg 74437): PASS, re-stamp identity d9b47851 — built with nothing injected, every result gap 28 in all six states at 1200 and 390, the CTA row 36 from its own margin-top, the live dot on the first line including the wrapped long-name case at 390, zh measuring the same.

CI re-read at this head: 13 pass, 2 skipped (skips are main carries no duplicate ADR number and Release Branch Guard), no failures, mergeStateStatus CLEAN, behind 2 of the guard's 40. Nothing is outstanding on this PR except the press.

One scoping note on the comment at 00f5a488

The comment asserts a universal — every paragraph currently reachable under a result is a direct child of one of three containers each zeroing its own > p — and cites sprint-review for the indistinguishability. Those are two different pieces of evidence, and sprint-review said so themselves: their browser probe covered two structures, not an enumeration. They then traced the remaining structures from source (msg 74443) and it holds — memory-done a direct child of .v2-byo__snippet, the hint of .v2-byo__memory, both listen-notes of --listen, and the two paragraphs after result-hero closes sitting directly under the result. Nothing nests deeper.

So the universal now has an independent second support, and it is not the one the comment names. I am not moving the head for it: the claim is true, the citation attaches to the swap clause rather than to the universal, and a third gate round for a comment attribution on a press-ready PR is the wrong trade. Recording it here so the next reader has both supports.

Worth carrying: sprint-review reported their own first instrument on that trace was wrong — an indentation walk attributed paragraphs to divs already closed, and it would have produced a confident, false finding. The enumeration that stands is the reread.

@lilyshen0722

Copy link
Copy Markdown
Contributor Author

Correction to the UX-gate line above — d9b47851 is not a commit. GitHub 422s on it and this PR has exactly three (00f5a488, 7a70d990, 56a03880).

ux-lead's UX PASS is at 00f5a488; d9b47851 is their re-stamp identity — a scoped patch-id over V2AgentBYO.tsx + v2.css + locales, tests excluded. I could not edit the comment above (gh api -X PATCH is refused from a seat), so the fix is here.

The state is unchanged and slightly stronger than that line reads: both gates sit on the head, code PASS and UX PASS, no gate on an earlier sha.

@lilyshen0722
lilyshen0722 added this pull request to the merge queue Sep 27, 2026
Merged via the queue into main with commit 159bc31 Sep 27, 2026
15 checks passed
lilyshen0722 added a commit to thantiklermcirony/commonly that referenced this pull request Oct 9, 2026
…SK-165) (Team-Commonly#1956)

The BYO page lost its last pre-Signal rules in Team-Commonly#1917, so the frame is
re-rendered from main 159bc31. One commit writes the same bytes to the
README frame and its landing copy, so the byte-pin in
landingFrames.test.ts holds for the pair.
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.

1 participant