Re: [css-grid] Margins and Auto-sized cells

On 11/02/2014 10:20 AM, Tab Atkins Jr. wrote:
> On Sun, Nov 2, 2014 at 3:26 AM, François REMY wrote:
>> ISSUE 2:
>>
>> =============
>>
>> In Chrome, the “margin” of the second <grid-item> is taken into account to
>> compute the breadth of the second row. I think it makes sense, but I’ve no
>> idea whether or not we should do this. I’m under the impression the spec
>> says we should use the “min-content” size of the grid item to compute the
>> track breadth, which (I believe) doesn’t contain the margin (so my
>> implementation doesn’t yield something great, here).
>>
>> FWIW, IE agrees with Chrome here and use the vertical margin as part of the
>> auto-sizing. I’m probably going to change my implementation to match, but I
>> wonder if the specs really says that.
>
> Ah, I think we don't explicitly state that you want the "outer"
> contribution.  I'll fix.

The contribution is, by definition, the outer size. See, e.g.

   # The min-content block-size contribution and max-content block-size
   # contribution of a block-level box is the block-size of the block
   # after layout, plus any block-axis margin, border, and padding.

in Sizing.

~fantasai

Received on Thursday, 18 December 2014 20:07:45 UTC