[css3-flexbox] absolutely positioned flexbox items

I have some questions about the static position of position:absolute flex
items.

The spec says, "If the element has two neighbors, its static position in
the main axis is exactly in the center of the packing space between them
when the flexbox is actually laid out."  This seems to only matter for
flex-pack:justify (the only way there's packing space between items), but
why the middle?  It's not hard to implement, but I wasn't sure what the use
case is. I would expect the static position to just be immediately after
the previous flex item.  E.g.:

+------------------+
|aaa bbb        ccc|
+-------------------+

Where bbb is a position:absolute flex item and aaa and ccc are flex items
that are being positioned by flex-pack:justify.  The spec would do
something like:

+------------------+
|aaa      bbb   ccc|
+------------------+

This doesn't seem that useful since bbb itself isn't centered, just the
left edge is in the center between aaa and ccc.

I also think the static position when there are no neighbors (i.e., a
position:absolute flex item with no other flex items) is a bit unexpected.
I wouldn't expect flex-pack to change the static position.

tony

Received on Wednesday, 4 January 2012 19:43:02 UTC