10

Haven't managed to stack divs when creating a flexbox layout. Either they push each other within the container div, or I have to use "position:absolute" on the overlay which gets the div out of its container context.

z-indices seem to not work at all.

I am using chrome latest version and was expecting this behaviour: http://dev.w3.org/csswg/css-flexbox/#painting

Here is a plunker with a basic flexbox layout: http://plnkr.co/edit/o2BAwvg3XV4YjwAwwmYR?p=preview to illustrate.

You will have to comment/uncomment the positioning in the definition of the .overlay class which is in the css.

4

1 回答 1

2

Ok, just realized z-index only works with positioned elements.

In the case presented, I needed to set the height of the container of the div .overlay (just put height:100% in .bodybox)

All is good now.

于 2014-06-08T18:34:41.210 回答