Re: [csswg-drafts] [css-grid] Track sizing algorithm and gutters

I think the fact that two independent implementations had the exact same bug is enough proof that the spec is misleading.  I see several issues with the [spec](https://drafts.csswg.org/css-grid/#algo-find-fr-size):
`Let leftover space be the space to fill minus the base sizes of the non-flexible grid tracks. `
1. the use of "base sizes" -- I don't generally consider gutters to have base sizes (or limits)
2. "grid tracks" in the quote above links to https://drafts.csswg.org/css-grid/#grid-track which explicitly defines the term as a separate entity from gutters
3. the fact that the above quote talks about a _subset_ of tracks distracts from the fact gutters between _all_ the tracks the item spans should be subtracted

It might be easier to leave §11.7.1. "Find the Size of an 'fr'" as is though and instead fix it in §11.7. "Expand Flexible Tracks" by changing "space to fill of the available grid space" to "space to fill of the available grid space minus the size of all the gutters" (the definite case), and "space to fill of the item’s max-content contribution" to "space to fill of the item’s max-content contribution minus the size of the gutters it spans" (the indefinite case).

The spec should also point out that if "space to fill" is negative then the "hypothetical fr size" is zero.

-- 
GitHub Notification of comment by MatsPalmgren
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/2201#issuecomment-358732046 using your GitHub account

Received on Thursday, 18 January 2018 18:07:53 UTC