Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Selecting all text in a paragraph and pasting from elsewhere doesn't replace the text #9218

Closed
noisysocks opened this issue Aug 22, 2018 · 4 comments
Assignees
Labels
[Feature] Paste [Type] Bug An existing feature does not function as intended

Comments

@noisysocks
Copy link
Member

noisysocks commented Aug 22, 2018

Describe the bug
Selecting all of the text in a paragraph block and then pasting content from Google Docs results in the pasted content being appended rather than the pasted content replacing the paragraph block.

To Reproduce

  1. Copy text into your clipboard from a Google Docs document
  2. Add a new post
  3. Type in some text to create a paragraph block
  4. Press Cmd+A to select all of the text in the block
  5. Press Cmd+V to paste the copied content
  6. The pasted content appears after the paragraph block

Expected behavior
The pasted content should replace the paragraph block.

Screenshots
google-docs

Desktop:

  • OS: macOS 10.13.6
  • Browser: Latest Chrome & Safari
@designsimply
Copy link
Member

I tested with current master @ c446d069f and found that the problem only happens when the paste from a docs.google.com document is multiline as noted by @kriskarkoski in #12443.

Tested with WordPress 4.9.8 and Gutenberg 4.5.1 master @ c446d069f using Chrome 70.0.3538.110 and Firefox 63.0.3 on macOS 10.13.6.

@kriskarkoski
Copy link

@designsimply Should we update the title to be more broad like the closed issue? I experienced it with Simplenote and Pages, so it's not limited to just Google Docs.

@designsimply designsimply changed the title Selecting all text in a paragraph and pasting from Google Docs doesn't replace the text Selecting all text in a paragraph and pasting from elsewhere doesn't replace the text Mar 13, 2019
@con322
Copy link

con322 commented Sep 25, 2019

Tested with copying text from Lorem Ipsum website and had the same issue where it's didn't replace the selected blocks but pasted the blocks (paragraph blocks) below the selected blocks.

Wordpress Version: 5.2.3
Browser: Chrome Version 77.0.3865.90 (Official Build) (64-bit)

@noisysocks
Copy link
Member Author

Looks like this works now!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Feature] Paste [Type] Bug An existing feature does not function as intended
Projects
None yet
Development

No branches or pull requests

5 participants