Skip to content

web: rework trace drawer layout and add instruction-object panel#254

Merged
gnidan merged 3 commits into
mainfrom
ui-tracedrawer-layout
Jul 13, 2026
Merged

web: rework trace drawer layout and add instruction-object panel#254
gnidan merged 3 commits into
mainfrom
ui-tracedrawer-layout

Conversation

@gnidan

@gnidan gnidan commented Jul 13, 2026

Copy link
Copy Markdown
Member

The trace playground drawer had two layout problems: the instructions/state row collapsed to its content height, leaving dead space below when the drawer was tall, and the instruction list was elided down to a window around the current step ("...N above/below").

This reworks the drawer's right-hand column into a flex column that fills the drawer:

  • Rows grow. The layout now uses an explicit full-height grid track, and the instructions/state row grows to fill available vertical space while its header stays a constant height. This removes the dead grey space.
  • Full instruction list. The instruction list renders every step instead of a window; it scrolls internally within its panel, and the active step is kept scrolled into view as the trace advances.
  • Instruction-object panel. A footer panel shows the selected step's full ethdebug/format/instruction object (offset, operation, context) as formatted JSON. A toggle in the footer header enables/disables it; it defaults on. When off, the instructions/state row reclaims the space.

Display-only; no trace or compilation semantics change. Best viewed on the deploy preview (open the trace playground and step through).

Fix the trace playground drawer so it fills the drawer height instead
of collapsing to content height and leaving dead space below. The
layout column now uses an explicit full-height grid track, and the
instructions/state row grows while its header stays fixed.

Render the full instruction list (removing the '...N above/below'
elision) with the list scrolling internally within its panel; the
active step is kept scrolled into view as the trace advances.

Add a footer panel that shows the selected step's full
ethdebug/format/instruction object (offset, operation, context) as
formatted JSON, gated by a toggle that defaults on.
@github-actions

github-actions Bot commented Jul 13, 2026

Copy link
Copy Markdown
Contributor
PR Preview Action v1.8.1
Preview removed because the pull request was closed.
2026-07-13 14:38 UTC

gnidan added 2 commits July 13, 2026 10:19
The instructions/state row still rendered at content height because
.trace-panels is itself a grid with no explicit row track: its single
implicit row was auto-sized, so the panels never stretched to the
grid's flex-grown height. Give .trace-panels (and its mobile variant)
an explicit minmax(0, 1fr) row so the panels fill the drawer and the
instructions list scrolls internally.

Default the ethdebug/format/instruction footer toggle to off.
The instructions panel stayed fixed-height because the class names
.opcodes-panel / .opcode-list are shared with the sibling TraceViewer
component, whose global (non-module-scoped) stylesheet caps them with
min-height: 200px; max-height: 300px. Those caps leaked onto the
drawer. Scope the drawer's rules as .trace-panel.opcodes-panel to
outrank the leaked single-class rule and reset max-height: none /
min-height: 0 so the panel grows to fill its grid cell.
@gnidan gnidan merged commit 24456c3 into main Jul 13, 2026
4 checks passed
@gnidan gnidan deleted the ui-tracedrawer-layout branch July 13, 2026 14:33
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