-
Notifications
You must be signed in to change notification settings - Fork 4.3k
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
>=7.4.0: New bug: Missing classes for core/group block #20347
Comments
Hi @strarsis,
I verified a Blue Group style was available and I verified that the class is-style-blue-group was applied to the dom of the editor and to the dom in the frontend. The block gained a blue background as expected. Could you provide additional details about your test website: plugins installed, the theme used, or any other information you may find relevant. |
@jorgefilipecosta: The following code is used for registering a block style in theme on backend: add_action( 'init', function() {
if(!function_exists('register_block_style')) return;
// Block styles
// Group
register_block_style('core/group', [
'name' => 'test',
'label' => 'Test',
]);
}); The moment I update to Gutenberg >= 7.4.0 (and reload the editor page), the group styles disappear because they don't have a WordPress version: 5.3.2 (latest) Edit: Even when I use an empty dummy theme or extend an existing core theme, e.g. the Twenty Twenty theme and add the block style registration code above, the block style is listed for the |
@talldan: I am really looking forward to the next Gutenberg release! 🐱 |
Describe the bug
Since release
7.4.0
of Gutenberg plugin (so7.5.0
is also included) the DOM element ofcore/group
block doesn't have classes anymore, notably for the selected block style (is-style-<block style name>
. The classes are still correctly updated in theAdvanced
/Additional CSS Class(es)
field.To reproduce
Steps to reproduce the behavior:
7.4.0
or higher (7.5.0
).core/group
block to be selected.core/group
block, to ensure no other markup is re-used from previous, correctly working Gutenberg releases, in order to reproduce this bug correctly.core/group
block.core/group
blocks (withwp-block-group
class) don't have any other classes assigned.Advanced
pane, notice that theis-style-*
class is correctly listed in theAdditional CSS Class(es)
field for that block.Expected behavior
The classes should be applied to the DOM element of the
core/group
block as in releases of Gutenberg prior to7.4.0
.Desktop (please complete the following information):
Additional context
When the Gutenberg plugin is disabled (only WordPress core used) or downgraded to a release prior to
7.4.0
, like7.3.0
, the issue goes away.The text was updated successfully, but these errors were encountered: