Skip to content
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

Columns Block: Spacing control visible in classic themes in WP 6.3 RC 1, but doesn't work #52909

Closed
laurelfulford opened this issue Jul 24, 2023 · 2 comments · Fixed by #53008
Assignees
Labels
[Feature] Layout Layout block support, its UI controls, and style output. [Feature] Themes Questions or issues with incorporating or styling blocks in a theme. [Status] In Progress Tracking issues with work in progress [Type] Bug An existing feature does not function as intended

Comments

@laurelfulford
Copy link
Contributor

Description

In the WordPress 6.3 RC 1, the Block Spacing control appears for the Columns block in the editor when using a classic theme, but it doesn't do anything -- no styles are output when you change its values.

Since it's the only block with this open when using a classic theme, and that it doesn't work, it seems like it shouldn't be visible after all.

Step-by-step reproduction instructions

  1. Start on a test site running WP 6.3 RC 1, and using a classic theme like Twenty Twenty One.
  2. Create a page, and add the Columns block.
  3. Change the horizontal Block Spacing value to either one of the 1-7 values, or a fixed PX value.
  4. See the gap doesn't change in the editor, or on the front-end. If you inspect the front-end, the usual styles that would be output to change the gap aren't there.

Screenshots, screen recording, code snippet

columns-block 2023-07-24 16_41_17

Environment info

I can recreate this with:

  • WordPress 6.3 RC 1 and the Twenty Twenty One theme, without Gutenberg.
  • WordPress 6.2.2 and the Twenty Twenty One theme, with Gutenberg 16.2.1.

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

@t-hamano
Copy link
Contributor

t-hamano commented Jul 25, 2023

Thanks for the report.

I was also able to reproduce this problem: without the Gutenberg plugin, there was at least the following difference between WP6.2 and WP6.3 about block supports:

WordPress 6.2.2

  • Group Block: Has padding support
  • Columns Block: Has padding support

WordPress 6.3-RC1

  • Group Block: Has padding, margin support
  • Columns Block: Has padding, margin, block spacing support

It appears that unintended Dimensions support has been added to the Classic theme. I mark this issue as a problem that should be fixed by WordPress 6.3.

@t-hamano t-hamano added [Type] Bug An existing feature does not function as intended [Feature] Themes Questions or issues with incorporating or styling blocks in a theme. labels Jul 25, 2023
@ndiego ndiego moved this to ❓ Triage in WordPress 6.3.x Editor Tasks Jul 25, 2023
@tellthemachines tellthemachines added the [Feature] Layout Layout block support, its UI controls, and style output. label Jul 26, 2023
@tellthemachines
Copy link
Contributor

tellthemachines commented Jul 26, 2023

I can reproduce this in Gutenberg trunk, though the spacing control seems to work in the editor, but doesn't output any value on the front end.

I'm not entirely sure why the spacing control is visible for Columns as it isn't for other flex layout blocks (e.g. Row). We shouldn't be showing it if it's not supported (though an argument could be made for supporting it in classic themes too).

Edit: Columns has sides defined for its block spacing, unlike other blocks with spacing support, so the issue is probably with the presence of this array not being accounted for when determining whether to show the control in the Dimensions panel.

@github-actions github-actions bot added the [Status] In Progress Tracking issues with work in progress label Jul 27, 2023
@tellthemachines tellthemachines moved this from ❓ Triage to 🏗️ In Progress in WordPress 6.3.x Editor Tasks Jul 27, 2023
@github-project-automation github-project-automation bot moved this from 🏗️ In Progress to ✅ Done in WordPress 6.3.x Editor Tasks Jul 27, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Feature] Layout Layout block support, its UI controls, and style output. [Feature] Themes Questions or issues with incorporating or styling blocks in a theme. [Status] In Progress Tracking issues with work in progress [Type] Bug An existing feature does not function as intended
Projects
No open projects
Development

Successfully merging a pull request may close this issue.

3 participants