Re: [csswg-drafts] [css-grid] Can the sizing algo be made to deal with this (#2356)

Note that if you have
```html
<div style="display: inline-grid">
  <div style="width: 100px; grid-column: 1 / 3"></div>
  <div style="width: 100px; grid-column: 2 / 4"></div>
  <div style="width: 100px; grid-column: 1 / 4"></div>
</div>
```

then the current spec sizes the columns as `50px 50px 50px`.

The algorithm above considers that the items with a span of 2 have no excess (their grid area is 100px and they are 100px wide). The 3rd item has excess, but it doesn't matter because the column excess is the minimum. So it's no-op.

However, we could eliminate the excess of the 3rd item by sizing the columns as `0px 100px 0px`, as produced by my algorithm from https://github.com/w3c/csswg-drafts/issues/2356#issuecomment-405056334.

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


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

Received on Thursday, 15 February 2024 19:33:43 UTC