W3C home > Mailing lists > Public > www-style@w3.org > July 2014

[css-scoping] Clarification about :host and pseudo-class combination usage

From: 河内 隆仁 <kochi@google.com>
Date: Fri, 25 Jul 2014 15:16:15 +0900
Message-ID: <CADP2=hpm68vJgF5cdCdS2M2CgM7UVFwArB_L7Y9Hn5qG+_vA1w@mail.gmail.com>
To: www-style@w3.org
Cc: Elliott Sprehn <esprehn@google.com>, Steve Orvell <sorvell@google.com>, Hayato Ito <hayato@google.com>
Hi,

Recently we had a discussion about how

(A) :host(::before) { ... }
(B) :host::before { ... }

should match.

Our local conclusion was that a pseudo-class (like ::before) works like a
combinator
and (A) should be rejected at CSS parser level as :host() can only contain
a compound selector, while (B) should match, like :host::shadow which is
already
in the spec (http://dev.w3.org/csswg/css-scoping/ , example 6).

However, we were not sure in which a pseudo element like ::before is
categorized,
as http://dev.w3.org/csswg/selectors4/, section 3.1 Structure and
Terminology, says
nothing about "pseudo element" (in contrast, pseudo class is a simple
selector).

Let us know your thoughts about (A) and (B) above.

Relevant Chromium bugs:
https://code.google.com/p/chromium/issues/detail?id=393490
https://code.google.com/p/chromium/issues/detail?id=393509

-- 
Takayoshi Kochi
Received on Friday, 25 July 2014 06:18:30 UTC

This archive was generated by hypermail 2.3.1 : Monday, 2 May 2016 14:39:23 UTC