Re: [csswg-drafts] [css-grid-1] Distribution of intrinsic sizes according to flex factors doesn't handle sum < 1 (#6078)

The CSS Working Group just discussed `Grid 1 - sum of flex factures < 1`, and agreed to the following:

* `RESOLVED: Accept proposal for continuous distribution of space to intrinsic grid tracks`

<details><summary>The full IRC log of that discussion</summary>
&lt;fantasai> Topic: Grid 1 - sum of flex factures &lt; 1<br>
&lt;fantasai> github: https://github.com/w3c/csswg-drafts/issues/6078<br>
&lt;fantasai> oriol: The specification says when taking into account the intrinsic contributions of items spanning flexible tracks, we distribute according to flex ratios of the tracks<br>
&lt;fantasai> oriol: We had a problem that all flexible tracks have 0fr, then have to divide by zero which is not well-defined.<br>
&lt;fantasai> oriol: So we resolved that in that case the distribution is done equally<br>
&lt;fantasai> oriol: Now we have the problem that this is not continuous<br>
&lt;fantasai> oriol: If you have 0fr to 0.00001fr, suddenly change from distributing equally to that track getting all the contribution<br>
&lt;fantasai> oriol: So proposal is to do the distribution continuously<br>
&lt;fantasai> oriol: If sum is >= 1 no change from now<br>
&lt;fantasai> oriol: if sum is zero, equal distribution as before<br>
&lt;fantasai> oriol: in between, we would [...]<br>
&lt;fantasai> oriol: we would multiply the space by the sum (which is &lt; 1) and distribute that space proportionally<br>
&lt;fantasai> oriol: and distribute the rest of the space equally<br>
&lt;fantasai> oriol: This gives continuity between 0 and 1<br>
&lt;fantasai> Rossen: Any feedback?<br>
&lt;emeyer> fantasai: I think it’s a good change that makes sense and gives us continuity between 0 and 1.<br>
&lt;emeyer> dbaron: Does anything else in CSS act like this?<br>
&lt;emeyer> fantasai: Flex acts a little like this.<br>
&lt;dholbert> yeah, the flexbox spec says something similar for flex-grow &lt; 1 -- we should be sure to make this as similar as possible.<br>
&lt;dholbert> for coherence<br>
&lt;fantasai> iank_: table percentage distribution acts a bit like this<br>
&lt;emeyer> fantasai: The main difference between this and flex is that here you distribute all the space but in flex you distribute some of it.<br>
&lt;fantasai> dbaron[m]: ok, seemed a little weird to only make the change in this place<br>
&lt;fantasai> iank_: Modulo web-compat...<br>
&lt;fantasai> iank_: I have a bug about 0frs and things<br>
&lt;fantasai> iank_: Depending on how widespread that is...<br>
&lt;fantasai> oriol: I don't think web-compat is problematic for this specific thing<br>
&lt;fantasai> oriol: Currently implementations are not taking into account intrinsic contributions of items spanning multiple flexible trakcs<br>
&lt;fantasai> oriol: gridNG implemented the right hting<br>
&lt;fantasai> oriol: if we had a compat problem, it would be more general problem<br>
&lt;fantasai> Rossen: not hearing any objections<br>
&lt;fantasai> RESOLVED: Accept proposal for continuous distribution of space to intrinsic grid tracks<br>
</details>


-- 
GitHub Notification of comment by css-meeting-bot
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/6078#issuecomment-866998209 using your GitHub account


-- 
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config

Received on Wednesday, 23 June 2021 16:46:41 UTC