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

Try to render flex layout styles as presets #39708

Closed
wants to merge 2 commits into from

Conversation

tellthemachines
Copy link
Contributor

What?

Tries to convert the flex layout styles into presets.

This is very much a WIP. It only addresses server rendered blocks for now, and it ignores properties for which arbitrary values can be set (e.g. gap).

Why?

Inspired by #36944 and #39374, mainly because I was wondering what a default approach would look like for layout.

How?

  • Flattens out the styles needed for flex layout so they fit neatly into classname -> property pairs.
  • Uses readable, verbose classnames for each property, because Classnames are Poetry (or something).

Testing Instructions

  1. Pick a server rendered block with flex layout that is NOT the Navigation block (because that one has custom logic for its styles). Query Pagination seems to be the only core one available.
  2. Check that changing its layout works as expected on the front end.

Screenshots or screencast

Screen Shot 2022-03-24 at 3 32 49 pm

@tellthemachines
Copy link
Contributor Author

Closing this now that we've landed #40875 🎉

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant