Skip to content

fix(webui): Wire view byte rows fit their own box - #125

Merged
404SecNotFound merged 1 commit into
mainfrom
claude/sweet-meitner-uo27fc
Oct 20, 2026
Merged

404SecNotFound merged 1 commit into
mainfrom
claude/sweet-meitner-uo27fc

Conversation

@404SecNotFound

Copy link
Copy Markdown
Owner

Summary

The Wire view's hex dump drew 16 bytes per row, which is wider than its box. The handoff noted this at phone width. Measuring showed it on desktop too: the wire shares the evidence band with the readout, so at 1440 wide the byte box is 445px against the ~461px a 16-byte row needs, and the ASCII column was clipped. It is visible in the committed 2026-10-19 docs/images/webui-run.jpg.

A viewport breakpoint (the first idea) cannot see this, because the box is narrower than the viewport. The dump now measures its own box (ResizeObserver, useLayoutEffect so no wide frame paints first) and draws 8 bytes per row when 16 do not fit. It remembers the widest box that overflowed, so it only tries 16 again in a wider box and cannot flap. The byte highlight is byte-addressed and unaffected.

Verification

  • New guards in WireView.test.tsx (3). Positive controls:
    • Against main's WireView.tsx, all 3 fail.
    • With the hysteresis condition removed, React throws Maximum update depth exceeded (the flap the guard exists to stop).
    • With the fix, all pass.
  • vitest: 261 on main, 264 here. tsc -b clean.
  • Chromium, real build, no-send run, byte box measured (scrollWidth vs clientWidth) and page overflow checked:
Width Bytes per row Byte box sideways scroll Page overflow
390 8 none none
768 16 none none
1280 8 none none
1440 8 none (was 16px, ASCII clipped) none
1920 16 none none
  • README screenshots regenerated with scripts/capture-webui-screenshots.py under Linux Chromium and checked by eye. webui-run.jpg now shows whole ASCII rows. webui-mobile.jpg came out byte-identical. The other five changed only in live values (clock cell, run counts).
  • No colour or token changed, so I did not re-run the contrast audit. Disclosed rather than claimed.

Documentation impact

  • Maintained documentation changed alongside the behavior, or unaffected surfaces are explained above. (docs/webui-silver-red-design.md gets a dated implementation note under the Wire view. The README text does not mention row width, so it is unaffected.)
  • CHANGELOG.md records the operator-visible change.
  • Historical decision records were preserved or received a dated addendum.
  • Documentation claims were checked against the implemented behavior.

Scope boundary

This is layout only. Parsing, dissection, and the bytes shown are unchanged. It does not touch the launch gate or any send path.


Generated by Claude Code

The hex dump drew 16 bytes per row in a box narrower than that row,
on a phone and also on desktop: the wire shares the evidence band
with the readout, so at 1440 wide its byte box is 445px against the
roughly 461 a 16-byte row needs, and the ASCII column was clipped.

The dump now measures its own box with a ResizeObserver and drops to
8 bytes per row when 16 do not fit, with hysteresis so it cannot flap.
Measured in Chromium at 390, 768, 1280, 1440 and 1920: no sideways
scroll in the byte box or the page. README screenshots regenerated.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01HbjsVBv8HQSQkAds6W5Y1v
@404SecNotFound
404SecNotFound merged commit 3bd43e1 into main Oct 20, 2026
13 checks passed
404SecNotFound pushed a commit that referenced this pull request Oct 20, 2026
Captured with scripts/capture-webui-screenshots.py against a fresh loopback
instance on current main. The run shot now shows the Wire view byte rows
from #125 fitting their box; the other changes are live values (clock,
rate, elapsed). webui-mobile.jpg was byte-identical and is unchanged.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01HbjsVBv8HQSQkAds6W5Y1v
404SecNotFound added a commit that referenced this pull request Oct 20, 2026
Six README screenshots recaptured with scripts/capture-webui-screenshots.py from current main; the run shot shows the Wire view byte rows from #125. webui-mobile.jpg was byte-identical. CI's path filter skips docs/** by design.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01HbjsVBv8HQSQkAds6W5Y1v
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.

2 participants