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

Add support for align-items: space-evenly #218

Conversation

nicoburns
Copy link
Collaborator

Objective

align-content has a space-evenly value in the CSS spec (see: https://developer.mozilla.org/en-US/docs/Web/CSS/align-content). This PR implements that value. For some reason we were already supporting it in justify-content but not align-content even though the spec defines it for both and the implementation is pretty simple.

Context

This is required for CSS Grid, but is a valid improvement in its own right so submitting separately.

@Weibye Weibye self-requested a review August 22, 2022 13:22
@alice-i-cecile alice-i-cecile added the enhancement New feature or request label Aug 22, 2022
Copy link
Collaborator

@alice-i-cecile alice-i-cecile left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Very simple change. Nice test and docs changes too :)

Copy link
Collaborator

@TimJentzsch TimJentzsch left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good, I just have some smaller remarks/questions

Copy link
Collaborator

@Weibye Weibye left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I appreciate the work!
Found an error in one of the test-fixtures which should be fixed.

The nits are non-blocking.

src/style.rs Outdated Show resolved Hide resolved
src/style.rs Outdated Show resolved Hide resolved
src/style.rs Outdated Show resolved Hide resolved
src/style.rs Outdated Show resolved Hide resolved
src/style.rs Outdated Show resolved Hide resolved
src/flexbox.rs Show resolved Hide resolved
test_fixtures/align_content_space_around_single_line.html Outdated Show resolved Hide resolved
@nicoburns nicoburns force-pushed the add-flexbox-align-content-space-evenly-support branch from 16a3dbb to 62e7432 Compare August 22, 2022 23:53
@nicoburns
Copy link
Collaborator Author

Comments addressed, and rebased on top of latest main

@alice-i-cecile alice-i-cecile merged commit d295d9b into DioxusLabs:main Aug 23, 2022
nicoburns added a commit to nicoburns/taffy that referenced this pull request Aug 23, 2022
* Add support for align-items: space-evenly

* Add AlignContent::SpaceEvenly to RELEASES.md

* Fix typo in AlignContent doc comments (gap -> gaps)

Co-authored-by: Andreas Weibye <13300393+Weibye@users.noreply.github.com>

* Fix align_content_space_around_single_line test

Co-authored-by: Andreas Weibye <13300393+Weibye@users.noreply.github.com>
jkelleyrtp pushed a commit that referenced this pull request Oct 10, 2022
* Add support for align-items: space-evenly

* Add AlignContent::SpaceEvenly to RELEASES.md

* Fix typo in AlignContent doc comments (gap -> gaps)

Co-authored-by: Andreas Weibye <13300393+Weibye@users.noreply.github.com>

* Fix align_content_space_around_single_line test

Co-authored-by: Andreas Weibye <13300393+Weibye@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants