Re: [css3-grid-layout] Grid-cell-stacking question

On Thu, Apr 14, 2011 at 6:03 PM, Rob Crowther <robertc@boogdesign.com> wrote:
> On 15/04/11 01:56, Tab Atkins Jr. wrote:
>> what would you do if two grid-items put in the same grid cell
>> specified different values?
>
> Have normal cascade rules apply and just accept the most specific value?

The problem is that the cascade has no effect on properties specified
on different elements.  You'd have to make up some new magic
surrounding this, such that the property on the grid items percolates
up to the grid cell, with the specificity it would have originally
had, and then cascades as if it was specified there.


> And now I think about it, would this work:
>
> #grid { grid-cell-stacking: rows; }
>
> Or does it need to be set on each cell?

That's potentially doable.  It doesn't have any particular problems,
at least, if you just specify that grid-cells defer to their superior
parent's value when they don't have an explicit value set for
grid-cell-stacking.

This is weirder if you do this behavior properly by just setting
'display' on the grid cells.

~TJ

Received on Friday, 15 April 2011 01:33:47 UTC