Skip to content

Conversation

@james-atticus
Copy link
Contributor

Description

When the editor is mounted in a different window, for example when using react-new-window, then copyToClipboard copies the selection from the main window.

Test plan

Tried to get a repro working with unit tests but couldn't get selection working with JSDOM.

Before

Copy using context menu gets the text from the parent window's selection:

Screen.Recording.2025-09-17.at.1.48.34.pm.mov

After

Screen.Recording.2025-09-17.at.1.56.39.pm.mov

@vercel
Copy link

vercel bot commented Sep 17, 2025

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Preview Comments Updated (UTC)
lexical Ready Ready Preview Comment Sep 17, 2025 4:02am
lexical-playground Ready Ready Preview Comment Sep 17, 2025 4:02am

@meta-cla meta-cla bot added the CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. label Sep 17, 2025
@ivailop7 ivailop7 added the extended-tests Run extended e2e tests on a PR label Sep 17, 2025
@etrepum
Copy link
Collaborator

etrepum commented Sep 17, 2025

#7790 probably fixes some more of these issues

@etrepum
Copy link
Collaborator

etrepum commented Sep 17, 2025

(or at least something like #7790, that someone is interested in actually finishing)

@etrepum etrepum added this pull request to the merge queue Sep 17, 2025
Merged via the queue into facebook:main with commit 0a760fd Sep 17, 2025
69 of 98 checks passed
This was referenced Sep 25, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. extended-tests Run extended e2e tests on a PR

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants