- From: Henrik Andersson <henke@henke37.cjb.net>
- Date: Wed, 13 Mar 2013 20:01:47 +0100
- To: François REMY <francois.remy.dev@outlook.com>, Brian Kardell <bkardell@gmail.com>, "liam@w3.org" <liam@w3.org>
- CC: Bjoern Hoehrmann <derhoermi@gmx.net>, "www-style@w3.org" <www-style@w3.org>
François REMY skriver: > If I'm not mistaken, here is the kind of selectors Brian's proposal is aimed to : > > :not(#a) { > selects all elements that are not #a > } > > :and(#a *, #b *) { > selects all elements that have both a #a and a #b parent > } > > :or(#a, #b) { > selects all elements that are either #a or #b > } > > The other proposals (like anyOf, oneOf...) can be emulated using those three. Currently, we already have ':not()' (but I think it's somewhat limited to simple selectors) and it's already possible to emulate ':or()' using commas. So "a :or(b,c) d" == "a b d, a c d". So what's really missing is the ':and' operator. > > (Brian if I'm wrong please correct me) > > Boolean algebra says that you can fake and using or. !(!X || !Y) == X && Y It works in the other direction too. !(!X && !Y) == X || Y
Received on Wednesday, 13 March 2013 19:02:24 UTC