-
Notifications
You must be signed in to change notification settings - Fork 4.5k
Closed
Labels
[Block] Query LoopAffects the Query Loop BlockAffects the Query Loop Block[Type] BugAn existing feature does not function as intendedAn existing feature does not function as intended
Description
Description
When you register a custom block style for the query (with register_block_style or the JavaScript equivalent) the link to where you add a new post to the query is in Styles section.
This is a bit difficult to explain without the screenshot:
When you open the block settings sidebar,
The link to add new posts is below the title "Styles" and below the buttons that you use to select the style variation.
Step-by-step reproduction instructions
Register any block style for the query loop.
My example looks like this:
<?php
/**
* Register block styles.
*/
function blue_note_register_block_styles() {
register_block_style(
'core/query',
array(
'name' => 'blue-note-query-slant',
'label' => __( 'Slanted images', 'blue-note' ),
'inline_style' => '.is-style-blue-note-query-slant .wp-block-post-featured-image {transform: rotate(-1deg);}',
)
);
}
add_action( 'init', 'blue_note_register_block_styles' );
Open the block editor.
Add a query block.
View the Styles section in the block settings sidebar.
Screenshots, screen recording, code snippet
Environment info
No response
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
Metadata
Metadata
Assignees
Labels
[Block] Query LoopAffects the Query Loop BlockAffects the Query Loop Block[Type] BugAn existing feature does not function as intendedAn existing feature does not function as intended