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

Footnotes not saved if the Custom Fields panel is open #54653

Open
Screenfeed opened this issue Sep 20, 2023 · 4 comments · May be fixed by #64794
Open

Footnotes not saved if the Custom Fields panel is open #54653

Screenfeed opened this issue Sep 20, 2023 · 4 comments · May be fixed by #64794
Labels
[Block] Footnotes Affects the Footnotes Block [Feature] Meta Boxes A draggable box shown on the post editing screen [Status] In Progress Tracking issues with work in progress [Type] Bug An existing feature does not function as intended

Comments

@Screenfeed
Copy link

Description

The footnotes block doesn't save new footnotes if the Custom Fields panel is open.
This happens only if footnotes already exist and we want to add more of them after the post has been saved at least once.

Ticket on trac.
The issue was reproduced during Test triage.

Step-by-step reproduction instructions

  1. Create a post with title and some content.
  2. Add a footnotes block: add 1 or 2 footnotes to your content.
  3. Save your post.
  4. While still in your block editor, go to Options (top right of the screen), Preferences (very bottom of the menu), Panels, enable "Custom fields", click "Show & Reload Page".
  5. Now the "Custom fields" panel is displaying your post's metas.
  6. Note that the meta storing the footnotes' content is named footnotes, without the _ prefix, so it is a public meta. Its value is a JSON string.
  7. Edit your post content by adding another footnote and save your post.
  8. Reload the page:
    • The anchor in the post content is still there.
    • The new footnote has disappeared from the footnotes block.
    • The post meta in the "Custom fields" panel doesn't contain the new footnote either.

Screenshots, screen recording, code snippet

No response

Environment info

  • WordPress 6.4-alpha.
  • Firefox 117.

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

@Mamaduka Mamaduka added [Block] Footnotes Affects the Footnotes Block [Type] Bug An existing feature does not function as intended [Feature] Meta Boxes A draggable box shown on the post editing screen labels Sep 20, 2023
@Mamaduka
Copy link
Member

I think the cause is the same as described in #23078.

@Screenfeed
Copy link
Author

I missed this ticket, I was focused on "footnotes" 😞
Indeed I expect any block using public post metas to fail.

@mrfoxtalbot
Copy link

Thank you for connecting the dots @Mamaduka and thanks for confirming @Screenfeed.

I will go ahead and close this as "duplicate".

@mrfoxtalbot mrfoxtalbot closed this as not planned Won't fix, can't repro, duplicate, stale Sep 20, 2023
@Mamaduka
Copy link
Member

@mrfoxtalbot, we might want to keep this open. There might be an intermediate fix for Footnotes by making the meta protected via the is_protected_meta filter.

@Mamaduka Mamaduka reopened this Sep 20, 2023
@github-actions github-actions bot added the [Status] In Progress Tracking issues with work in progress label Aug 26, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Block] Footnotes Affects the Footnotes Block [Feature] Meta Boxes A draggable box shown on the post editing screen [Status] In Progress Tracking issues with work in progress [Type] Bug An existing feature does not function as intended
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants