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 gap style #3036

Merged
merged 5 commits into from
Dec 17, 2024
Merged

Add gap style #3036

merged 5 commits into from
Dec 17, 2024

Conversation

mhsmith
Copy link
Member

@mhsmith mhsmith commented Dec 11, 2024

This PR is stacked on top of #3033, which should be merged first. To view only the relevant changes on the "Files changed" page, open the commits menu at the top left and use shift-click to select a range of commits.

I haven't updated all the examples that could benefit from this, but I've done one each with a row and a column layout.

PR Checklist:

  • All new features have been tested
  • All new features have been documented
  • I have read the CONTRIBUTING.md file
  • I will abide by the code of conduct

Sorry, something went wrong.

@mhsmith mhsmith changed the title Gap Add gap style Dec 11, 2024
@HalfWhitt
Copy link
Member

@mhsmith Some more commits over on #3033 now

@mhsmith
Copy link
Member Author

mhsmith commented Dec 13, 2024

gap would interact with potential future column_gap and row_gap properties in the same way as margin interacts with margin_left, etc.:

  • You could set gap to an integer to set both gaps to the same value. This is the only option at the moment, because we only support 1-dimensional containers.
  • Or set gap to a 2-tuple to set them to different values.
  • Or set column-gap and row-gap individually.

@mhsmith mhsmith marked this pull request as ready for review December 15, 2024 03:47
@HalfWhitt
Copy link
Member

gap would interact with potential future column_gap and row_gap properties in the same way as margin interacts with margin_left, etc.:

Thank you for pointing this out... directional_property's current implementation in Travertino would eventually need some generalizing to handle this.

@mhsmith mhsmith requested a review from freakboy3742 December 17, 2024 00:28
Copy link
Member

@freakboy3742 freakboy3742 left a comment

Choose a reason for hiding this comment

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

👍 Looks exactly like what I'd expect.

@freakboy3742 freakboy3742 merged commit 075533b into beeware:main Dec 17, 2024
41 checks passed
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.

Equivalent of CSS gap (padding between children)
3 participants