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

The Working Group just discussed `Can the sizing algo be made to deal with this`.

<details><summary>The full IRC log of that discussion</summary>
&lt;dael> Topic: Can the sizing algo be made to deal with this<br>
&lt;dael> github: https://github.com/w3c/csswg-drafts/issues/2356<br>
&lt;florian> https://florian.rivoal.net/csswg/grid/grid-span-auto-001-ref.html<br>
&lt;dael> florian: I was laying out a page of manga using grid so each cell is a grid. It should layout like ^<br>
&lt;florian> https://florian.rivoal.net/csswg/grid/grid-span-auto-001.html<br>
&lt;dael> florian: Defining a bunch of columns and rows and everything can fit, but it's manual.<br>
&lt;dael> florian: Here's what you get ^<br>
&lt;dael> florian: It has unneeded empty spaces.<br>
&lt;TabAtkins> Very simple example: https://github.com/w3c/csswg-drafts/issues/2356#issuecomment-379878492<br>
&lt;dael> florian: I think this boils down to current sizing algo not considering enough things. It's descried as a possibly improvable heuristic. If we agree this is a good thing to solve...it sounds desireable...I think this is linear programming solvable by constraints. I'm not good enough at math to put the steps but I think this is solvable.<br>
&lt;dael> TabAtkins: Simple example ^<br>
&lt;dael> TabAtkins: [explains example] We take the largest of the planned increases so we're not loosly wrapping each item. Ideal would be the latter image. It's one possible version.<br>
&lt;dael> florian: I believe an algo exists that we could solve it, or are we too locked into compat.<br>
&lt;dael> fantasai: I think we should be able to make the adjustments. I don't think anyone depends on this slight amount of slack. As time goes on we might get more constrained but I think we're not at that state. IF we could solve it it would be great, but I don't know how to do it.<br>
&lt;dael> florian: I might be able to research the thoroetical algo but I'm not righ to say if impl-able.<br>
&lt;dael> fremy: I've been working on some layouts and you can do a post-process to reduce the sizing.<br>
&lt;dael> TabAtkins: This example (bottom of link) it shows one possible switch. BUt there's several ways to solve it like making the column 300 and the last one goes to 0.<br>
&lt;dael> florian: Some examples have a range of solutions, mine has one solution.<br>
&lt;dael> florian: I think it's worth looking into if there's a general option that we're not blocked in. I'd appriciate a mathematically inclided person to help. Maybe do the current algo and squish would work. I<br>
&lt;dael> fremy: browsers are impl grid and we don't want to change whole algo so that's easier.<br>
&lt;dael> TabAtkins: And your site may be doing it for you. In the manga example your images have known widths, it's just easier if CSS does it for you.<br>
&lt;dael> fantasai: TabAtkins and I can take an action to look at post-processing step to see if that works. Maybe send a email to bert with a link to this issue to see if he has some insight.<br>
&lt;dael> ChrisL: We was talking to people from Monash (sp?) univeristy with expertese.<br>
&lt;TabAtkins> s/making the column 300 and the last one goes to 0/making the columns 50,250,0, which is a big change from the current way they lay out/<br>
&lt;dael> fantasai: We also had Caesar (sp?) who was working on an impl of Bert's grid spec.<br>
&lt;ChrisL> s/(sp?)//<br>
&lt;fantasai> s/Caesar/César/<br>
&lt;Rossen> dael, here's the illustration that should go with the BFC discussion (issue 2452) https://lists.w3.org/Archives/Public/www-archive/2018Apr/0001.html<br>
&lt;ChrisL> s/Monash (sp?)/Monash/<br>
&lt;dael> florian: I think the trickier part is that this is more complicated. If we have auto sizing it's simplier. If you have one min and one max you span. It's much harder to explain to people that don't know CSS but I'll try.<br>
&lt;dael> astearns: Anything more?<br>
&lt;dael> florian: Nope.<br>
</details>


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

Received on Tuesday, 10 April 2018 12:38:56 UTC