Re: [css-flexbox] available space and max-height

On Wed, Dec 2, 2015 at 5:06 PM, Tab Atkins Jr. <jackalmage@gmail.com> wrote:
> On Tue, Dec 1, 2015 at 5:11 PM, Christian Biesinger
> <cbiesinger@google.com> wrote:
>> On Tue, Dec 1, 2015 at 8:09 PM, Tab Atkins Jr. <jackalmage@gmail.com> wrote:
>>> On Tue, Dec 1, 2015 at 5:01 PM, Christian Biesinger
>>> <cbiesinger@google.com> wrote:
>>>> On Tue, Dec 1, 2015 at 7:58 PM, Tab Atkins Jr. <jackalmage@gmail.com> wrote:
>>>>> On Tue, Dec 1, 2015 at 4:49 PM, Christian Biesinger
>>>>> <cbiesinger@google.com> wrote:
>>>>>> However that still leaves the preferred width computation which only
>>>>>> says "Place all flex items into lines of infinite length.", which is
>>>>>> quite the opposite of respecting any height or max-height properties.
>>>>>> Shouldn't it be affected by that?
>>>>>
>>>>> No, "width: max-content;" never cares about the "max-width" property
>>>>> on the element.  (For the purpose of figuring out what "max-content"
>>>>> resolves to - later, in actual layout, it of course matters.)
>>>>
>>>> No, that's not what I meant. This is still about how max-height should
>>>> affect the max-content width. See the testcase I gave originally -- if
>>>> a column flexbox has a max-height set, shouldn't the intrinsic width
>>>> computation break the boxes into multiple lines and give a width that
>>>> can fit the multiple flex rows (visually, the columns)?
>>>
>>> Your testcase doesn't invoke max-content at all.  Your desired result
>>> is what you get, yes, but from elsewhere in the algorithm, as fantasai
>>> outlined.
>>
>> Huh? Why do you say that? It's an inline-flex, therefore
>> shrink-wrapped, therefore should be sized at max-content. No?
>
> I'm confused. You talk about height/max-height, and a column flexbox
> (vertical lines, whose breaking is affected by the height), but now
> you're talking about shrinkwrapping, which affects the width.
>
> Can you break down exactly what your question is?  There's enough
> assumptions flying that I can't figure it out.

So, this was not clear in this thread, but I was always wondering
about the expected *width* in the presence of a (max-)*height*, for
column flexboxes. fantasai cleared up where this is defined for the
actual layout, so now I only have the question left about the
*intrinsic* width.

In other words, this testcase: http://codepen.io/anon/pen/pJLwYp

You say "vertical lines, whose breaking is affected by the height" but
in the intrinsic size algorithm I don't see any mention that the
breaking is affected by the height. Instead it says "Place all flex
items into lines of infinite length." which is literally the opposite
of them being affected by the height.

Greg: for your other reply just now, I'm talking specifically about
the intrinsic size part of the spec -
https://drafts.csswg.org/css-flexbox/#intrinsic-sizes

-Christian

Received on Wednesday, 2 December 2015 22:19:12 UTC