[shadow-styling] Which node the :ancestor selector matches

The text in [1] is at best unclear about the fact that :ancestor
actually selects the shadow host and not the ancestor matching the
compound selector inside the pseudo function. I was confused about the
meaning of :ancestor until I read [2] which is very clear about it:

"The selector :ancestor(<selector>) matches the host element if it or
any of its ancestors matches <selector>."

Could the spec say something like that, given that it's correct?

[1] http://dev.w3.org/csswg/shadow-styling/#ancestor-selector
[2] http://www.polymer-project.org/articles/styling-elements.html#theming-an-element

Rune Lillesveen

Received on Monday, 17 March 2014 15:08:14 UTC