-
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
Are shadow controls supposed to be enabled by default in classic themes? #58908
Comments
I think this is part of #58298 Edit: @carolinan Just saw you engaged already in the specific PR and you're probably aware of the issue. Sorry, please ignore then. |
I got confused because looking at #58766 it only addressed theme.json, not classic themes. @madhusudhand |
Adding this to the 6.5 board for likely discussion and perhaps some quick fixes as this impacts adding appearance tools to classic themes. cc @tellthemachines and @andrewserong. |
@annezazu this feature is independent from appearance-tools; as I understand it this issue is about the inability to opt out of it in classic themes. The shadow feature has been in core for about a year though, so this can't strictly be classed as a regression. |
@tellthemachines, while the shadow feature has been in core for a long time, I think the control at the block level in the block inspector is new, and landed only a few weeks ago: #57654 — so it might be something that needs following up on. I'll just ping @vcanales and @mikachan for visibility, too. |
Oh good point @andrewserong, then I guess this is still eligible to fix post-Beta. |
Yes! Sorry for not clarifying further. Those changes landed very recently and details matter. |
Sure, my main point is this issue is unrelated to appearance-tools. The shadow controls will always display in classic themes whether appearance-tools are enabled or not. |
Looks like another PR landed last week that then consolidated shadow effects into the Border panel in #58466. It'd be good to confirm with @vcanales and @madhusudhand what the intended behaviour is, since there's been a bit of movement with these controls, and I wonder if that's a factor at play here 🤔 |
Update: I wonder if the problem is that the core Line 193 in 6e8d515
This means that
I'm not too sure what the fix could be here, given that default value (typically |
@madhusudhand Could you clarify what you see as the next steps here? 🙏 |
@andrewserong Thank you for the inputs. I am taking a look at theme-json-resolver for a possible fix by conditionally setting the shadow to gutenberg/lib/class-wp-theme-json-resolver-gutenberg.php Lines 296 to 297 in 8c58423
I am not sure yet, but I guess the core function Please share your thoughts on this approach. cc: @getdave Update: Created #58967 to test this approach. |
Thanks for opening #58967 @madhusudhand! That approach looks close to me, but to neaten things up, I think it might work better if on classic themes it set |
@madhusudhand Have you managed to make any progress with this yet? We're 1 week out from RC 1 and it seems like landing Shadow support in a manner that is inconsistent with other supports is undesirable. @andrewserong has offered support with reviews so perhaps the work could be divided up? |
@getdave I believe this one can likely be closed out now that #58766 has been merged. @madhusudhand was there anything else that needed to be done before we close this? |
@getdave @andrewserong This issue is closed out by #58766. There isn't anything required for classic themes. Marking it as resolved. |
Description
I found it surprising that for a classic theme, I did not have to opt-in for the new shadows controls. They are enabled by default on the supported blocks.
Both custom spacing, color palettes, border, link color and now appearance tools have been opt-in, disabled by default.
How do theme developers opt-out of the feature?
Step-by-step reproduction instructions
On 6.5 alpha:
Activate a classic theme like Twenty Sixteen.
In the block editor, add an image, column or button
Open the block settings panel, locate the "Border and Shadow" panel.
Screenshots, screen recording, code snippet
No response
Environment info
6.5-alpha-57580
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
The text was updated successfully, but these errors were encountered: