Skip to content

Preserve multiline job logs#592

Merged
bgentry merged 1 commit into
masterfrom
bg/fix-preformatted-log-panel
Jun 12, 2026
Merged

Preserve multiline job logs#592
bgentry merged 1 commit into
masterfrom
bg/fix-preformatted-log-panel

Conversation

@bgentry

@bgentry bgentry commented Jun 12, 2026

Copy link
Copy Markdown
Contributor

Job attempt logs can contain newline-delimited records, but the UI rendered them through the same shared panel used by structured JSON content. The plain code markup collapsed log line breaks, while wrapping the shared component in pre/code would put JSONView's interactive disclosure markup inside preformatted code.

This splits the copyable panel chrome from plaintext semantics. Job logs and wait expressions now use a string-only plaintext panel with explicit preformatted whitespace behavior, while JSONView uses the copyable shell directly and keeps its structured React tree outside preformatted markup. Storybook now includes multiline log and wrapped-expression examples so those layouts are easier to inspect.

This builds on the issue identified in #530, but takes a narrower approach so the log viewer and JSON viewer keep their distinct rendering behavior.

Closes #530.

Device Before After
Desktop 01-master-desktop 02-pr592-desktop
Mobile 03-master-mobile 04-pr592-mobile

Job attempt logs can contain newline-delimited records, but the UI rendered
them through a shared panel that treated all content as ordinary inline code.
That collapsed multiline log output into a single visual paragraph and made
the same component responsible for both copyable panel chrome and plaintext
semantics.

Split the reusable copy button shell into a copyable panel and make the
plaintext panel string-only. Job logs and wait expressions now render through
`pre`/`code` markup with explicit whitespace behavior, while the JSON viewer
keeps its structured interactive React tree outside preformatted code markup.

Focused component coverage now asserts multiline plaintext markup, exact
clipboard text, and the JSON viewer's non-preformatted structure. Storybook
also covers multiline logs and wrapped expressions so the two plaintext
layouts are visible.
@bgentry bgentry force-pushed the bg/fix-preformatted-log-panel branch from 49e1de8 to 4587c1c Compare June 12, 2026 01:13
@bgentry bgentry requested a review from brandur June 12, 2026 01:37
@bgentry bgentry marked this pull request as ready for review June 12, 2026 01:37
@bgentry

bgentry commented Jun 12, 2026

Copy link
Copy Markdown
Contributor Author

@codex review

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. Already looking forward to the next diff.

Reviewed commit: 4587c1c359

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@bgentry bgentry enabled auto-merge (squash) June 12, 2026 01:44
@bgentry bgentry merged commit b596e58 into master Jun 12, 2026
21 checks passed
@bgentry bgentry deleted the bg/fix-preformatted-log-panel branch June 12, 2026 01:47
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