- From: fantasai <fantasai.lists@inkedblade.net>
- Date: Mon, 16 Jul 2012 22:21:46 -0400
- To: "Kang-Hao (Kenny) Lu" <kennyluck@csail.mit.edu>
- CC: WWW Style <www-style@w3.org>
On 06/28/2012 10:18 AM, Kang-Hao (Kenny) Lu wrote: > I am having trouble understanding the algorithm here, and I'll > appreciate some help, for example, a pointer to a previous discussion. > > > 9.2. Line Length Determination > > # 3. Determine the flex base size and hypothetical main size of each > # item: > # > # ... > # Otherwise, if the flex container's main-axis is parallel to the > # item's inline-axis, lay out the item using the available space and > # its flex basis if the item is inflexible, > > Question 1: What does use the available space *and* its flex basis mean? > Using its flex basis as the available space? Using the maximum of > available space from the flex container and the flex basis? We've rewritten this part of the algorithm, hopefully it's clearer now: http://dev.w3.org/csswg/css3-flexbox/#line-sizing > Question 2: What is the flex base size of > > <div style="display: flex; width: fit-content"><!--floated container--> > <div style="flex: 0 0 50%;"> > </div> > </div> > > The flex item is inflexible and the percentage is resolved against an > flex container with indefinite width and hence indefinite by definition. > How do you resolve 50% at this point? As Tab says, that's undefined. It's now clearly specified as such, though. :) > Question 3: What does "sized under a min-content or max-content > main-size constraint" mean? What are the examples besides "width: > min-content" and "width: max-content" on the flex container? Another example would be 'min-content' or 'max-content' on an ancestor of the flex container while the flex container is auto. The most common case, however, is shrinkwrapping an ancestor: it needs to size its content under both min and max constraints in order to know what values to put into the fit-content expression. Does that help? ~fantasai
Received on Tuesday, 17 July 2012 05:22:19 UTC