WordPress / gutenberg

The Block Editor project for WordPress and beyond. Plugin is available from the official repository.
https://wordpress.org/gutenberg/
Other
10.57k stars 4.22k forks source link

File Block: unexpected or invalid content when a link is pasted in #54700

Open MadtownLems opened 1 year ago

MadtownLems commented 1 year ago

Description

On one of our sites, we found a lot of "unexpected or invalid content" on File Blocks. Looking into it, we think it was caused by pasting links over the filename.

Step-by-step reproduction instructions

  1. Add a File Block
  2. Disable inline embed. The file name should now be visible and editable
  3. Paste some basic link markup as the filename, such as <a href='https://wordpress.org/'>WordPress</a> (The block preview will just show WordPress as a link.)
  4. Publish/update the post. It does so without issue.
  5. Reload the editor. You should now see that "This block contains unexpected of invalid content."

Screenshots, screen recording, code snippet

No response

Environment info

WP 6.3.1, Gutenberg 16.6.0 (Also WP 6.3.1 without Gutenberg and WP 6.2.2 without Gutenberg)

Please confirm that you have searched existing issues in the repo.

Yes

Please confirm that you have tested with all plugins deactivated except Gutenberg.

Yes

github-actions[bot] commented 1 year ago

Hi, This issue has gone 30 days without any activity. This means it is time for a check-in to make sure it is still relevant. If you are still experiencing this issue with the latest versions, you can help the project by responding to confirm the problem and by providing any updated reproduction steps. Thanks for helping out.

MadtownLems commented 1 year ago

I've confirmed this issue is still present on WordPress Core 6.4-RC-1

github-actions[bot] commented 1 year ago

Hi, This issue has gone 30 days without any activity. This means it is time for a check-in to make sure it is still relevant. If you are still experiencing this issue with the latest versions, you can help the project by responding to confirm the problem and by providing any updated reproduction steps. Thanks for helping out.

MadtownLems commented 1 year ago

This means it is time for a check-in to make sure it is still relevant

Yes - the issue still exists in 6.4.1