-
Notifications
You must be signed in to change notification settings - Fork 2k
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
Gutenberg Copy Paste Styles - Unclear how to resolve clipboard permissions error #74542
Comments
📌 SCRUBBING : RESULT - Replicated / Could Not Replicate / Uncertain
Update - found the introduction of the Copy Styles feature here: WordPress/gutenberg#45477 (from Gutenberg 15.0). It seems this clipboard permissions issue is expected; but it's pretty tough to tell what to do about it. (From the original PR:)
📌 FINDINGS/SCREENSHOTS/VIDEO
Self-Hosted Example Screen.Capture.on.2023-03-28.at.17-58-27.mov📌 ACTIONS
|
Hey @Gustavo-Hilario , how did you enable the clipboard permissions? Thank you! not urgent as looks like folks are working on this already :) |
It's a cross-origin iframe issue that didn't come to my mind when I first implemented it 😞 . Fortunately, the fix seems to be relatively simple enough, at least from <iframe
<!-- ... -->
allow="clipboard-read"
/> Note that adding it in the devtools doesn't seem to work without reloading the frame. Firefox seems to require the same attribute, while Safari seems to be working without it 🤔 . Anything I can do to help add it? 🙇 |
@kevin940726 you might be able to add it here: https://github.com/Automattic/wp-calypso/blob/trunk/client/gutenberg/editor/iframe.tsx |
@mattwiebe Thanks! I created #75082. I don't think I'm able to setup the dev environment though. Will be nice if someone can help me test it 🙇 . |
I think we can close this now that #75082 is merged? Please re-open it if the problem still exists 🙇 ! |
It doesn't work on Firefox 114. Workaround More info |
@pablorq Thank you so much — this was driving me crazy in FF. |
In my particular case, it happened with Reusable Blocks. Trying to copy the styles of the block to another similar block (just not reusable) launched that warning |
It's still happening even after adding |
This error persists. Safari 17, MacOS Sonoma, |
I had to also set |
You rock mate! It is still an issue on Firefox, but works with your solution! |
Thank you Style copy-paste with: WP 6.6.1, on:
with True for
work fine Have a nice Sunday |
Quick summary
When we try to copy and paste styles into another block, we get this error message:
Unable to paste styles. Please allow browser clipboard permissions before continuing.
Even after enabling clipboard permission for WordPress.com, the styles cannot be pasted.
Steps to reproduce
Unable to paste styles. Please allow browser clipboard permissions before continuing.
What you expected to happen
I'd expect the customization made to the block to be copied and passed into the new one.
What actually happened
Pasting styles don't work even on a simple paragraph block. It seems to be working more like the
Copy Block
option.Screen.Capture.on.2023-03-16.at.15-55-53.mp4
Impact
Some (< 50%)
Available workarounds?
Yes, easy to implement
Platform (Simple and/or Atomic)
Simple, Atomic
Logs or notes
The workaround here is to copy and paste the block and edit the content.
This feature isn't publicly documented yet. I can't find anything on our support documentation that teach us how to use these options. Also, the error message doesn't give us details on what and how to adjust the clipboard settings:
Unable to paste styles. Please allow browser clipboard permissions before continuing.
The text was updated successfully, but these errors were encountered: