Admin: Use flex layout for Community Events form to improve alignment and wrapping #11085
Admin: Use flex layout for Community Events form to improve alignment and wrapping #11085hmbashar wants to merge 3 commits intoWordPress:trunkfrom
Conversation
… and wrapping - Set .community-events-form to display: flex - Add gap: 5px, align-items: center, and flex-wrap: wrap - Mirror the same rules in the RTL stylesheet - Improves spacing and responsiveness without markup or JS changes - No compiled/minified assets included
|
The following accounts have interacted with this PR and/or linked issues. I will continue to update these lists as activity occurs. You can also manually ask me to refresh this list by adding the Core Committers: Use this line as a base for the props when committing in SVN: To understand the WordPress project's expectations around crediting contributors, please review the Contributor Attribution page in the Core Handbook. |
Test using WordPress PlaygroundThe changes in this pull request can previewed and tested using a WordPress Playground instance. WordPress Playground is an experimental project that creates a full WordPress instance entirely within the browser. Some things to be aware of
For more details about these limitations and more, check out the Limitations page in the WordPress Playground documentation. |
|
Changing to a flex layout also allows us to remove a number of parameters that are now irrelevant; I've just committed those removals to this PR. Should probably be re-tested. |
huzaifaalmesbah
left a comment
There was a problem hiding this comment.
Looks good just need this changes 5px to 0px margin for fix spinner
Thanks for the help. Yes, your changes look good. I noticed the spinner moved slightly downward, but after removing the margin, it now appears centered. Thanks for the update. Co-authored-by: Huzaifa Al Mesbah <huzaifah4m@gmail.com>



Trac ticket: https://core.trac.wordpress.org/ticket/64753
Summary
Convert the Community Events form to a flex layout for better alignment, Ved spacing, and wrapping in the Dashboard widget.
LTR only. No markup or JS changes.
Context
The current inline flow can crowd controls and misalign labels/inputs at narrower widths or with longer localized labels.
A flex container with gap, vertical centering, and wrapping provides consistent alignment and improves responsiveness.
Changes
.community-events-form:
Files Changed (source only)
src/wp-admin/css/dashboard.css
Accessibility
Improves visual clarity and grouping without altering semantics or focus order.
Works with zoom and longer localized strings due to wrapping.
No change to keyboard navigation or focus indicators.
Backward Compatibility
CSS-only change scoped to .community-events-form.
No markup/JS changes.
Uses well-supported flexbox and gap properties.
Screenshots
Testing Instructions
Implementation Notes