WordPress / gutenberg

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

"Query Type" missing from Query Loop block; can no longer use it to inherit current query? #67252

Open cheestudio opened 1 day ago

cheestudio commented 1 day ago

Description

I went to create a Template Part for Search Results and I noticed I was not able to allow the Query Loop block to inherit the current query. I then went to multiple sites running 6.7.1 and found the same result.

I disabled all plugins and used TwentyTwentyThree to rule out any plugins or theme conflicts. This setting is 100% missing.

Step-by-step reproduction instructions

  1. Add a Query Loop
  2. Notice the setting is missing

Screenshots, screen recording, code snippet

Image

Image

Environment info

No response

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

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

Please confirm which theme type you used for testing.

cheestudio commented 1 day ago

Follow up: I now see that the "default behavior" is to have the query loop inherit by default:

https://make.wordpress.org/core/2024/09/23/core-editor-improvement-simplified-query-loop-block-with-smarter-defaults-intuitive-settings/

The documentation has not been updated, which is very confusing:

https://wordpress.org/documentation/article/query-loop-block/#inherit-query-from-template

Anyway, this would be fine, except it doesn't actually work; I'm adding it to a Template Part and it's wanting to just query a post type and it's not reacting to user searches.

jeflopodev commented 16 hours ago

This one is also about Query Loop & Template parts: https://github.com/WordPress/gutenberg/issues/38684