WordPress / gutenberg

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

Footnotes in sync patterns can't be edited #60982

Open druxstr opened 4 months ago

druxstr commented 4 months ago

Description

Expected

Footnotes content should be editable.

Happening

When a Footnotes block is added to a Sync Pattern, footnotes can't be edited anymore.

The footnotes can't be edited from the Post/Page content, as the Sync Pattern is stored in the content as :

<!-- wp:block {"ref":id} /-->

When editing the Sync Pattern itself (using "Edit original"), a message says that Footnotes are not supported :

Footnotes are not supported here. Add this block to post or page content.

Result : Users can edit the footnote content neither from the Post content, nor from the Pattern editor.

This issue occurred on a blank new WordPress with no plugin.

Step-by-step reproduction instructions

From the editor :

  1. Add a footnote to some content using the Footnotes block
  2. Add a Group
  3. Move the Footnotes block in the Group
  4. Turn the Group into a Sync Pattern (Group > Options > Create pattern)
  5. Try to edit the footnote

You now can't edit the footnote content from the Visual or Code editor.

Screenshots, screen recording, code snippet

wp-uneditable-footnotes.webm

Environment info

WordPress version : 6.5.2 Theme : Twenty Twenty-Four Browser : Brave, Firefox Device : Desktop

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

talldan commented 3 months ago

@druxstr That's an interesting one as footnotes doesn't work like other blocks (it can't be inserted in the same way) and probably for this reason.

Thanks for flagging it though, it's something to think about.