Skip to content

feat(opencode): improve pasted summary toggling and styling#21205

Open
haddoumounir wants to merge 2 commits intoanomalyco:devfrom
haddoumounir:feat/paste-summary
Open

feat(opencode): improve pasted summary toggling and styling#21205
haddoumounir wants to merge 2 commits intoanomalyco:devfrom
haddoumounir:feat/paste-summary

Conversation

@haddoumounir
Copy link
Copy Markdown

Issue for this PR

Closes #8501

Type of change

  • Bug fix
  • New feature
  • Refactor / code improvement
  • Documentation

What does this PR do?

I improved pasted summary behavior in the TUI prompt so pasted content is easier to inspect and edit before submit.

Main changes:

  • I added expand/collapse behavior for pasted summaries directly from the prompt.
  • I improved pasted summary rendering/styling so multiple pasted blocks are easier to distinguish.
  • I improved submit time expansion so full pasted text is correctly included when sending.
  • I kept related test hardening updates to reduce flaky behavior in status popover interactions and runner cancellation paths.

Why this works:

  • Prompt state and extmark updates stay in sync when toggling summaries.
  • Expanded/collapsed text is handled consistently before submit.
  • Related timing sensitive paths now have stronger test coverage.

How did you verify your code works?

  • I manually validated paste summary toggle behavior in the TUI prompt.
  • I updated related tests for status popover and runner cancellation paths.
  • I validated the branch is clean and focused into two commits.

Screenshots / recordings

I added a short before/after video showing paste summary toggle behavior and submit behavior.

demo.mp4

Checklist

  • I have tested my changes locally
  • I have not included unrelated changes in this PR

@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Apr 6, 2026

The following comment was made by an LLM, it may be inaccurate:

Related PRs Found:

Based on my search, here are potentially related PRs addressing similar pasted summary features:

  1. feat(tui): Allow to expand pasted text (AKA "pasted summary") - feat(tui): Allow to expand pasted text (AKA "pasted summary") #8496

    • Directly related: Addresses expanding pasted text in the TUI
  2. feat(tui): make pasted summaries expandable/collapsible in prompt - feat(tui): make pasted summaries expandable/collapsible in prompt #17248

    • Directly related: Adds expand/collapse functionality for pasted summaries in the prompt
  3. feat(app): collapse large pasted input blocks - feat(app): collapse large pasted input blocks #15411

    • Related: Handles collapsing large pasted input blocks

These PRs all address expand/collapse behavior for pasted content in the TUI prompt, which is the core feature of PR #21205. You may want to verify that #21205 is not duplicating work from these previous PRs, or if it's a refinement/improvement on top of them.

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.

[FEATURE]: Allow to expand the pasted text (e.g. [Pasted ~1 lines])

1 participant