webkit-transform breaks z-index on Safari

前端 未结 3 1154
梦谈多话
梦谈多话 2020-12-17 14:34

Problem

I\'m trying to make a layer appear like it\'s a wall falling down, revealing the layer behind it. I\'ve setup two fixed div positions. The \

3条回答
  •  隐瞒了意图╮
    2020-12-17 14:53

    My rotating element wasn't suitable to have a neighbour to the background, but I fixed it by applying

    transform: translateZ(1000px);
    transform-style: preserve-3d;
    

    to the parent of the rotating element. Safari now thinks it's 1000px infront of the background.

提交回复
热议问题