-
Notifications
You must be signed in to change notification settings - Fork 804
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
Forms: modernize use of global style controls #41120
Comments
Adopting core block supports or rendering controls to their slots would trigger the display of the tabs in the block inspector sidebar. That might lessen the burden on the current sidebar's real estate. I'm not sure but the block inspector's style tab may not support custom panels being rendered within it. If that limitation is confirmed, it could be a blocker to making this less busy via those tabs.
This will be easier said than done with the way field blocks currently try to juggle two sets of styles, one each for the label and input. More details in the
There are some edge cases around styling elements via global styles instead of block types. Depending on how some blocks are styled the direct targeting of the This isn't to say it can't be done, only that it will need some thorough testing and possibly some extra styling tweaks to the block.
Layout block support might require a re-think of the current form field width controls and styles. There's also some work underway in Gutenberg around the Grid layout support. This might provide a smoother pathway to migrating current Form blocks over to block supports in terms of layout. I spent some time today trying to get a little extra context around Forms and all the available blocks, their current settings/styles and what block supports we might be able to migrate to or adopt. The following are notes on general issues I found. I'm out of time today but will soon create issues for those that haven't already been reported and tracked. Bugs
Styling Related Issues
Non Styling Issues
|
Sidebar for each field is quite busy, and we're missing some basic styling controls. Let's update each field to rely on declared block support for global styles and expand on options.
Note spacing issue bug visible in the screenshot.
Button block is better example:
List of design tools missing at form level:
supports.align
)supports.color.button
)supports.layout
)supports.layout
)supports.typography
)Text fields
Note form elements missing in
theme.json
supports
:The text was updated successfully, but these errors were encountered: