Re: [css-grid] Containing block for abs.pos. grid items when the grid overflows

On 03/25/2015 04:03 PM, Tab Atkins Jr. wrote:
> The behavior falls out of the placement definitions.  The abspos has
> one line for its placement - its column-start is 2.  Its default span
> is 1, per spec, so its column-end gets computed to 3.

I think it's a bit trickier than that.

For a normal grid item, "grid-column:  2 / auto" would indeed give us a
span of 1. But I don't think that's true of an abspos item -- there, the
spec says:

 # "auto" [...] contributes the corresponding
 # padding edge of the grid container as a line.
http://dev.w3.org/csswg/css-grid/#abspos-items

So the spec says this item's containing block starts at grid-line 2, and
ends at the right edge of the grid container's padding-box.  So, its
containing block has a negative width.

~Daniel

Received on Thursday, 26 March 2015 00:14:29 UTC