Skip to content

feat(tui): paste clipboard on right click#36471

Open
aditya-vithaldas wants to merge 1 commit into
anomalyco:devfrom
aditya-vithaldas:right-click-paste
Open

feat(tui): paste clipboard on right click#36471
aditya-vithaldas wants to merge 1 commit into
anomalyco:devfrom
aditya-vithaldas:right-click-paste

Conversation

@aditya-vithaldas

@aditya-vithaldas aditya-vithaldas commented Jul 12, 2026

Copy link
Copy Markdown

Issue for this PR

Closes #36456

Type of change

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

What does this PR do?

Makes right-click dispatch the existing prompt.paste command when mouse capture is enabled and the prompt is focused. This supports clipboard text and images while preserving the experimental right-click copy behavior.

Unlike #32064, which is limited to Windows-specific terminal behavior, this fixes the default captured-mouse path reported on Linux and avoids pasting behind dialogs by requiring prompt focus.

How did you verify your code works?

  • bun typecheck from packages/tui
  • bun test test/app-lifecycle.test.tsx test/index.test.tsx (3 passed)

Screenshots / recordings

Not included. Clipboard insertion is an input interaction without a stable visual before/after state.

Checklist

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

@github-actions github-actions Bot added the needs:compliance This means the issue will auto-close after 2 hours. label Jul 12, 2026
@github-actions

Copy link
Copy Markdown
Contributor

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

Found one related PR:

fix(tui): fix right-click paste on windows (#32064)

This PR (#32064) appears to be related as it also addresses right-click paste functionality in the TUI. You may want to check if there's overlap in the implementation or if this is a continuation/fix of an earlier attempt.

@github-actions github-actions Bot removed the needs:compliance This means the issue will auto-close after 2 hours. label Jul 12, 2026
@github-actions

Copy link
Copy Markdown
Contributor

Thanks for updating your PR! It now meets our contributing guidelines. 👍

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.

Right-click paste doesn't work in TUI when mouse capture is enabled

1 participant