-
Notifications
You must be signed in to change notification settings - Fork 4.7k
Description
Description
It seems that the option "inherit query from template" is missing in 6.7.
From what I can see, the inherit attribute is still there though, and it looks like the logic is that its set to true in the site editor and false in the block editor automatically.
The problem is, we can use query loops in the site editor, that are not intended for archive display.
If I want to show a list of posts in header or footer template for example, this is now forced to be true, meaning it will be forced to connect to the global $wp_query.
I'm not sure if this breaks existing implementations, I assume it would as the attributes would be changed when visiting the site editor and the block attributes are upgraded automatically.
Step-by-step reproduction instructions
- Goto the site editor
- Edit header template
- Add a query loop
- Notice there is no possibility to edit the query loop attributes, such as choosing a post type etc.
- Visit the frontend, its using the global
$wp_query
Screenshots, screen recording, code snippet
chrome_8IZ6zauWHY.mp4
Environment info
Same issue on both 6.7-alpha-59113 and nightly build 6.7-RC3-59353 of WordPress
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
Please confirm which theme type you used for testing.
- Block
- Classic
- Hybrid (e.g. classic with theme.json)
- Not sure