W3C home > Mailing lists > Public > public-css-archive@w3.org > September 2017

Re: [csswg-drafts] [selectors] Functional pseudo-class like :matches() with 0 specificity

From: Brad Kemper via GitHub <sysbot+gh@w3.org>
Date: Thu, 28 Sep 2017 18:21:42 +0000
To: public-css-archive@w3.org
Message-ID: <issue_comment.created-332921990-1506622890-sysbot+gh@w3.org>
Sorry. I tend to think of ID selectors as 10x of class selectors, and class selectors as 10x of type selectors, etc. But that only works if the counts are less than 10 in each slot. The problem lessens if you use base 100 instead of base 10, I guess. But let me rephrase to be more like how the spec explains it:

If “A” is the count of id selectors, “B” is the count of class or attribute or pseudo class selectors, and “C” is the count of type or pseudo-element selectors, then instead of just looking at the counts in the order of “a,b,c”, you would look at “a,b,c,a1,b1,c1,a2,b2,c2”, etc., where the “1” means one level of :matches(), “2” means 2 levels of embedding `:matches(something:matches(this-selector))`, etc. 

-- 
GitHub Notification of comment by bradkemper
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/1170#issuecomment-332921990 using your GitHub account
Received on Thursday, 28 September 2017 18:21:32 UTC

This archive was generated by hypermail 2.4.0 : Tuesday, 5 July 2022 06:41:18 UTC