[csswg-drafts] [css-display] Use "computes to" instead of "behaves as" for display: contents on unusual elements.

emilio has just created a new issue for https://github.com/w3c/csswg-drafts:

== [css-display] Use "computes to" instead of "behaves as" for display: contents on unusual elements. ==
https://drafts.csswg.org/css-display/#unbox says:

> display: contents behaves as display: none.

Which means that the computed value of `display` should still be `contents`. This adds unnecessary complexity, and this is not how all engines implementing this section right work.

In particular, it requires a mapping from element to "is really display contents", or something of the sort. Firefox used to have that, but it caused a lot of performance issues for no gain, so I removed it in https://bugzilla.mozilla.org/show_bug.cgi?id=1303605.

(Note that I removed that mapping earlier without realizing the correctness issue it introduced, https://bugzilla.mozilla.org/show_bug.cgi?id=1453702, which I fixed computing to none instead of contents, which also aligns with Blink and WebKit).

Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/2755 using your GitHub account

Received on Monday, 11 June 2018 04:13:06 UTC