Re: [css3-flexbox] containing block for absolutely positioned children of a flexbox

One clarification -- of course, in my example, the abspos div's 
y-position would be taken from its static position which is inside the 
flexbox (at its placeholder's position).

But the part I'm wanting to sanity-check is that the x-position (from 
"left: 10px") is with respect to the outer div, not to the flexbox.

Thanks,
~Daniel

On 02/09/2012 10:05 AM, Daniel Holbert wrote:
> Just wanted to be sure I'm understanding correctly: flexboxes do *not*
> act as containing blocks for absolutely-positioned children, correct?
> Instead, the flexbox's closest ancestor that is a block will serve that
> purpose. (?)
>
> e.,g. if I have
> <div id="outer">
> <div style="display:flexbox">
> <div style="position:absolute; left: 10px">test</div>
> </div>
> <div>
>
> ...then my understanding is that the absolutely positioned element is
> positioned with respect to div#outer -- *not* with respect to the
> flexbox -- since div#outer is the containing block. Is that right?
>
> Thanks!
> ~Daniel
>

Received on Thursday, 9 February 2012 19:01:30 UTC