Re: [css-grid] Doubt about grid-auto-flow stack

On Wed, Jul 16, 2014 at 3:02 AM, Manuel Rego Casasnovas <rego@igalia.com> wrote:
> On 15/07/14 23:12, Tab Atkins Jr. wrote:
>> On Tue, Jul 15, 2014 at 1:27 PM, Manuel Rego Casasnovas <rego@igalia.com> wrote:
>>> Hi,
>>>
>>> I've a doubt regarding stack value in grid-auto-flow property.
>>>
>>> Let's use a simple example to illustrate it. We have a 2x2 grid with
>>> grid-auto-flow stack that contains 3 items:
>>> * A with grid-row: 1 and grid-column: 1.
>>> * B and C with grid-row: auto and grid-column: auto.
>>>
>>> B and C would be both stacked on row 1 and column 2.
>>>
>>> However, I'd like to confirm what happens if we have another item with
>>> grid-row: 2 and grid-column: auto.
>>> IMHO it would be considered an auto-placed item and be stacked on row 1
>>> and column 2 too (somehow ignoring the grid-row: 2 property).
>>>
>>> Is it right?
>>
>> I think it technically is right, but it shouldn't be.  The special
>> "stack" behavior should only affect things that are auto in both
>> dimensions, I think.
>
> If it doesn't affect items with one defined demission like the one in
> the example with grid-row: 2 and grid-column: auto.
>
> Where these items should be placed?
> A) In the first column on row 2.
> B) In the first empty cell on row 2.
>
> If the answer is B), what would happen if we have more items with the
> same properties (grid-row: 2 and grid-column: auto)?

I'm thinking we'd just act normally - they'd spread out in the given
row/column like normal.  Only the "fully" auto-placed items would
stack.

~TJ

Received on Wednesday, 16 July 2014 15:08:41 UTC