W3C home > Mailing lists > Public > public-css-archive@w3.org > June 2018

Re: [csswg-drafts] [css-grid-2] support automatic grid span for subgrids?

From: fantasai via GitHub <sysbot+gh@w3.org>
Date: Tue, 12 Jun 2018 20:33:54 +0000
To: public-css-archive@w3.org
Message-ID: <issue_comment.created-396724169-1528835633-sysbot+gh@w3.org>
An example would be, say I place the subgrid in its parent grid using `grid-row: 3`. This expands to `grid-row-start: 3; grid-row-end: auto`. Currently `auto` resolves to `span 1`, so the subgrid spans lines 3-4 in the parent grid and has only one row regardless of its `grid-template-*` properties.

We could alternately make it calculate `auto` from the contents of the subgrid, e.g. if the subgrid declared `grid-template-rows: subgrid; grid-template-areas: "a" "b" "c" "d"`, we would resolve the subgrid’s `grid-row-end` as `span 4`. It would then span lines 3-7 in the parent grid and have four rows.

-- 
GitHub Notification of comment by fantasai
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/2565#issuecomment-396724169 using your GitHub account
Received on Tuesday, 12 June 2018 20:33:56 UTC

This archive was generated by hypermail 2.4.0 : Saturday, 2 July 2022 03:21:09 UTC