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

[css-flexbox][css-grid] Proposal: make column-rule work in Flex and Grid layout + add row-rule and rule, like for gap #9482

Closed
benface opened this issue Oct 17, 2023 · 3 comments
Labels

Comments

@benface
Copy link

benface commented Oct 17, 2023

Right now, if you want a border/line between Flex items or Grid cells, you need hacks like * + * { border-top: 1px solid #ccc; } or more complex to handle multiple rows and columns together. These hacks fall apart very quickly, for instance if the first item has display: none. It would be nice to add a property explicitly for this, and there is one that currently works in multi-column layout: column-rule. Note that the related property column-gap already works in Flex and Grid, along with row-gap and the gap shorthand. I propose adding row-rule and rule as well.

@SebastianZ
Copy link
Contributor

Thank you for bringing that up! Note that rules and more advanced gap decorations for Flexbox, Grid and also Table layout are already discussed in #2748 and #6748.

Gap decorations were also discussed again at a face-to-face meeting back in July. There it was decided to break the feature down to basically what you are suggesting (and leave the rest of the features suggested in the other issues for later improvements).

I'll try to find the time to summarize what was discussed back then and write up a full proposal for that. So it can finally be turned into a specification.

Sebastian

@benface
Copy link
Author

benface commented May 15, 2024

Hey @SebastianZ, any news? This would be a super useful addition to CSS.

@benface benface changed the title [css-flexbox][css-grid] Make column-rule work in Flex and Grid layout + add row-rule and rule, like for gap [css-flexbox][css-grid] Proposal: make column-rule work in Flex and Grid layout + add row-rule and rule, like for gap May 16, 2024
@benface
Copy link
Author

benface commented Dec 23, 2024

Closing, since there is a whole Editor's Draft spec now! 🎉

@benface benface closed this as completed Dec 23, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants