You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The block preview doesn't work when editing a template part in the site editor. I can still click in and edit the block fine. The error doesn't happen when using a pattern.
Versions
WordPress version: 6.5.3
Genesis Custom Blocks version: 1.7.0 pro
The text was updated successfully, but these errors were encountered:
Since in site editor it's not running in a post, instead of a valid post_id, it sends the template part name instead, like theme//template-part-name, and so the request fails.
A quick fix for making Genesis Custom Blocks work is to add a dummy post_id in the Components props, like :
To try in the built version of block-editor.js (published on wordpress.org), find urlQueryArgs:{inner_blocks in the file, and change it like urlQueryArgs:{post_id:0,inner_blocks
This souldn't have too much impact if you're not fetching post data in your custom blocks I think… But it's a nice workaround instead of the error banner.
Bug summary
The block preview doesn't work when editing a template part in the site editor. I can still click in and edit the block fine. The error doesn't happen when using a pattern.
Versions
The text was updated successfully, but these errors were encountered: