Re: [csswg-drafts] [css-display] Should anonymous boxes always inherit through the box tree?

> Obviously it wouldn't be surprising at all if there were an explicit rule targeting the span and setting the color.

Yes, that would of course be normal and expected. As far as I can tell that's not germane to this issue, tho? Again, the issue is that, without something like what's described here, the inheritance behavior of text depends on whether or not its immediate parent element generates a box. This is inconsistent with how inheritance works for elements, thus the surprise.

> I'm arguing that being styled via inheritance from a display:contents element is no more surprising and the resulting behavior does not necessarily warrant introducing the entirely new concept of "text node styles".

I'm very confused by this statement. You're correct that being styled via inheritance from a display:contents element isn't surprising. That's what we're trying to ensure will happen!  Right now, as vaguely written, text *won't* inherit from a display:contents parent element; our concept of "text nodes" carrying styles ensures that it *does*, like normal elements do.

---

To help alleviate my confusion about what position you're advocating for, @anttijk, can you quickly say what color you expect the text to be in the two examples in the first comment?

-- 
GitHub Notification of comment by tabatkins
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/1118#issuecomment-306340780 using your GitHub account

Received on Monday, 5 June 2017 23:41:37 UTC