Is there a bug in Chrome's CSS visibility rendering?

前端 未结 2 1069
北恋
北恋 2020-12-16 17:18

There seems to be odd behavior in Chrome 15+ when using this particular combination of CSS properties, namely an outer element with visibility hidden and fixed positioning a

相关标签:
2条回答
  • 2020-12-16 17:38

    Yes, it's a bug. It seems to be a Web-kit regression bug that started happening in version 535, and is noticeable in many versions of Chrome even up through 18.x

    kizu's hack is fine as a workaround until they address it again.

    0 讨论(0)
  • 2020-12-16 17:56

    Yep, there is a bug, definitely: I managed to reproduce it in my version of Chrome too.

    In case you'll want to fix it, you could add the “webkit's hasLayout” fix, -webkit-transform: translateZ(0); to wrapper or inner element, this makes Chrome to render the block properly.

    Here is a fixed fiddle: http://jsfiddle.net/kizu/bHzWN/6/show/

    0 讨论(0)
提交回复
热议问题