Skip to content

Conversation

@sreya
Copy link
Contributor

@sreya sreya commented Nov 16, 2025

No description provided.

When pasting from the right-click context menu, text was being pasted
twice due to event bubbling. The paste event fired on the textarea and
then bubbled up to the parent container, causing both the Terminal's
textarea handler and the InputHandler's container handler to fire.

Added stopPropagation() to the textarea's paste event handler to prevent
the event from bubbling to the parent, ensuring paste only happens once.

Fixes: Double paste when using right-click menu
Tested: Right-click paste and keyboard paste (Ctrl+V/Cmd+V) both work correctly
@sreya sreya changed the title Fix double paste issue from right-click context menu fix: prevent double paste issue from right-click context menu Nov 16, 2025
@sreya sreya merged commit 98ed4f1 into main Nov 16, 2025
5 checks passed
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