Re: [whatwg/fullscreen] How does top layer interact with CSS isolation? (#71)

It seems to me `isolation` makes the element create a stacking context, and top layer also makes element create a stacking context, so the element create a stacking context, there is nothing wrong. The `isolation` would just be useless here, because top layer already makes the element create a stacking context.

An element wouldn't have multiple stacking context (actually having multiple stacking contexts doesn't make anything different for a single element, since stacking context only affects how its descendent would be placed relative to each other in z-order).

The problem for Chromium here is that, later `<div>`s have higher rendering position (closer to the eyes) if they create stacking context and have equal `z-index` (which is `auto` by default), since they are in the same parent stacking context.

Previously, UAs use `z-index: 2147483647` to workaround this issue, but this isn't perfect. The spec should have addressed this issue via stating that "it is rendered as an atomic unit as if it were a sibling of its root". But thinking a bit further, I think there is still some issue with the spec.

I think the idea is that, the top layer should be rendered on top of the whole page, and nothing can cover top layer elements except another top layer element. But it seems to me the current spec still allows something in the root stacking context with a positive `z-index` to be rendered over top layer, which seems wrong to me.

I guess it should be a slibing to the root stacking context, rather than a child... We probably need a CSS expert here to get things right...

(I'm quite sleepy at the moment and gonna sleep soon, so I could be wrong...)

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/whatwg/fullscreen/issues/71#issuecomment-270378853

Received on Wednesday, 4 January 2017 14:11:49 UTC