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

RE: [selectors] Assistance requested in figuring out the data model of pseudo-elements

From: François REMY <francois.remy.dev@outlook.com>
Date: Wed, 26 Nov 2014 19:11:33 +0100
Message-ID: <DUB405-EAS256E5FE5613A368D690EFCCA5700@phx.gbl>
To: "'Tab Atkins Jr.'" <jackalmage@gmail.com>
CC: "'Benjamin Poulain'" <benjamin@webkit.org>, "'www-style list'" <www-style@w3.org>
± On Wed, Nov 26, 2014 at 9:56 AM, François REMY
± <francois.remy.dev@outlook.com> wrote:
± > ± A "generator of a disjunction" makes :matches() a special syntax
± > form, not a ± real pseudo-class.  That would be somewhat easier, but
± > it would also be ± weird.  Dunno if I wanna go down that road.
± >
± > Also, it's not a disjunction. If it was, the following two would be equivalent:
± >
± >         a:matches(.b c, .d e)
± >         a.b c, a.d e
± >
± > If I understood the situation correctly, they are not.
± 
± No, it's more complicated than that.  Let's rephrase in explicit AND/OR terms,
± to make it clear how it's in DNF:
± 
± (a AND .b c) OR (a AND .d e)
± 
± It's a disjunction of conjunctions.

If we extend to pseudo-elements, this won't stay accurate; 
==> [a]:matches([b], ::before)
==> ([a] AND [b]) OR ([a] AND ::before)

Which is why I argue we probably shouldn't allow that.
Received on Wednesday, 26 November 2014 18:12:05 UTC

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