Re: [css-flexbox] abspos & align-self: stretch

For align, it's only align-items/align-self, but not align-content.
Tested in Edge 20.10240.16384.0

For justify it is justify-content as you say.

-Christian

On Thu, Apr 21, 2016 at 5:04 PM, Tab Atkins Jr. <jackalmage@gmail.com> wrote:
> On Thu, Apr 21, 2016 at 1:18 PM, Tab Atkins Jr. <jackalmage@gmail.com> wrote:
>> On Thu, Apr 21, 2016 at 12:40 PM, fantasai
>> <fantasai.lists@inkedblade.net> wrote:
>>> On 03/30/2015 12:33 PM, Christian Biesinger wrote:
>>>>
>>>> Thanks, I'll do the same. I was wondering if I should stretch it
>>>> anyway even though it doesn't technically participate in flex layout.
>>>> baseline is also the same as flex-start, I assume.
>>>
>>>
>>> Greg is right, it just gets treated as flex-start. Here's the
>>> spec text:
>>>
>>>   # The static position of an absolutely-positioned child
>>>   # of a flex container is determined such that the child
>>>   # is positioned as if it were the sole flex item in the
>>>   # flex container, assuming both the child and the flex
>>>   # container were fixed-size boxes of their used size.
>>>
>>> If the child is a fixed-size box, then stretch degrades to
>>> flex-start.
>>>
>>>> Would be nice if the spec was a bit more explicit about it!
>>>
>>>
>>> Agreed. :) We're updating the note about "static position
>>> rectangle" to help clarify the mental model here. (It's
>>> currently got no referrants, so something went missing at
>>> some point somewhere.) Also adding a note pointing out how
>>> 'stretch' falls back to 'flex-start'.
>>
>> And staticpos of an abspos is now more thoroughly defined in Align:
>> <https://drafts.csswg.org/css-align/#justify-abspos-static>
>>
>> Until "static position rectangle" is actually defined in Position for
>> the other layout modes, this is *technically* hand-wavey, but you get
>> the gist.
>
> Aaaaaand, never mind.  The static position, as defined in Flexbox, (a)
> doesn't pay attention to justify-self at all, because that doesn't
> work on flex items, and (b) *does* pay attention to justify-content
> and align-content.  This behavior is attested in Edge, so I'd prefer
> not to change it (and Christian wants to match it).
>
> So that means there really isn't any hope of unifying static
> positioning into the simple Alignment model, and it just needs to be
> manually defined by every layout mode. :(
>
> ~TJ

Received on Thursday, 21 April 2016 21:40:42 UTC