Skip to content

feat(desktop): collapse long messages behind Show more - #5179

Open
nawazish2 wants to merge 1 commit into
block:mainfrom
nawazish2:feat/collapse-long-messages
Open

feat(desktop): collapse long messages behind Show more#5179
nawazish2 wants to merge 1 commit into
block:mainfrom
nawazish2:feat/collapse-long-messages

Conversation

@nawazish2

Copy link
Copy Markdown

Summary

Long agent output (and big pastes) used to dominate the channel. Messages now clamp at ~12 lines with a Show more / Show less toggle.

Fixes #5175

Behavior

  • Collapsed by default when content is taller than ~240px
  • Fade + toggle under the fold
  • Expand state is per mounted row (not persisted)
  • Search query or route highlight force-expands so matches aren't hidden
  • Diffs / huddles / wave attachments are unchanged (only the markdown body path)
  • Virtualizer height estimate caps at the collapsed body size (+ toggle)

Test plan

  • pnpm test (desktop) — includes new clamp helpers
  • Manual: open a channel with a multi-page agent message → Show more / less
  • Manual: search for text inside a long message → body expands

Agent dumps and long pastes used to fill the channel. Clamp message
bodies around ~12 lines with a local Show more / Show less toggle.

Search and route highlights force-expand so matches stay visible.
Timeline height estimates cap at the collapsed size so the virtualizer
doesn't leave huge empty gaps.

Signed-off-by: Nawazish Khan <175596916+nawazish2@users.noreply.github.com>
@nawazish2
nawazish2 requested a review from a team as a code owner August 7, 2026 11:35
@chatgpt-codex-connector

Copy link
Copy Markdown

You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard.
To continue using code reviews, you can upgrade your account or add credits to your account and enable them for code reviews in your settings.

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.

feat(desktop): collapse very long messages behind a "Show more" toggle

1 participant