-
Notifications
You must be signed in to change notification settings - Fork 643
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-grid] Proposal: Ability to name grids and reference them from subgrids #1375
Comments
I think this is totally separate from subgrids; this is actually asking for the ability to make arbitrary descendants into grid items, rather than just children. This, unfortunately, was explicitly rejected earlier in Grid's design, as it means you need to search arbitrarily far down to know how to layout the grid. |
Does that explicit rejection also kill an approach like this?
|
That looks like the same thing, yes. (Making an arbitrary descendant into a grid item.) |
It was rejected as “we don't think we want to do this atm”, not as “this is fundamentally incompatible with the model”. The original proposal was to do it with something like On a related note, there was some brief consideration of multiple, overlapping named grids. We ended up with the named lines feature instead. But something to think about maybe. |
As part of the subgrid discussion, I feel it could be very useful to name grids and reference them elsewhere. Here’s a quick top-of-mind rough sketch:
This would sidestep the need to
display: subgrid
every element along a DOM branch. There’s precedent for naming things that are referenced elsewhere (e.g., keyframe animations) so the idea isn’t alien, though the syntactical approach here might be.The text was updated successfully, but these errors were encountered: