- From: Tab Atkins Jr. via GitHub <noreply@w3.org>
- Date: Mon, 10 Nov 2025 08:07:59 +0000
- To: public-css-archive@w3.org
@alisonmaher and I talked this over in an informal breakout. We'd like to avoid Option 1 if possible. Mixing fixed and intrinsic columns in *non*-repeat situations is fine, and imposing a restriction when repeat() is involved is kinda weird imo. No problems arise if there *aren't* any spanning items, so it feels bad to prevent people from using that combo. Option 2 is very reasonable in the simple case, but has an issue - you need to define a notion of "same keyword". * Say the columns are `repeat(..., 100px auto auto)`, as in the example in Alison's post. Then it's pretty obvious that the two `auto`s are "the same", and we can reasonably max() the values we calculated for them (200px for 2nd, 150px for 3rd), setting them *both* to 200px. * Say the columns are `repeat(..., 100px minmax(0px, auto) minmax(0px, auto))`. I think it's a little less self-evident that the two intrinsic columns are "the same", but pretty reasonable to conclude that they are. We'd get the same calculations - 2nd columns is 200px, 3rd is 150px, so we'd set them both to 200px. * Say the columns are `repeat(..., 100px minmax(0px, auto) minmax(1px, auto))`. Here they're clearly not "the same". But in practice, they are! It would be pretty strange if this situation resulted in the two columns being set to 200px and 150px. * Say the third column in the repeat was `minmax(0.000001px, auto)` - when does it round to 0 in the impl and count as "the same"? We don't like exposing precision details like that. We *could* bite the bullet and say that two identical `minmax()`s *aren't* "the same"; maybe only naked keywords can qualify. That would allow the common/simple case to still work fine, but `minmax()` isn't exactly rare, especially `minmax(0, ...)`. (And as a note for future Alison, the number of repetitions needed to capture all possible spanner locations is `2+(largest span - 2)/(length of repeat list)`, rounded down. So say a repeat list of 3, and a spanner of 6. `2 + round(down, (6 - 2) / 3)`, that's 3 repetitions. That's correct - if the repeat list is ABC, then a span-6 item could cover CABCAB, which requires 3 repetitions to give enough columns.) I think Option 3 doesn't fix the issue. Option 4, as noted, is just easy to be wrong. But it's cheaper and easy! ----------------- I think on balance, Option 2 is probably best. I think we should just bite the bullet on both rounding-observability and on slightly-different values giving different results: `minmax(0, auto)` is identical to `minmax(0, auto)`, and different from `minmax(1px, auto)`, but `minmax(0.00001px, auto)` might or might not be equivalent depending on the impl. This gives the same correct results for span-1 items, gives good results for all reasonable cases with spanning items, and the problematic cases are generally okay. -- GitHub Notification of comment by tabatkins Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/12899#issuecomment-3510035178 using your GitHub account -- Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config
Received on Monday, 10 November 2025 08:08:00 UTC