W3C home > Mailing lists > Public > www-style@w3.org > March 2011

Re: selectors in :any

From: L. David Baron <dbaron@dbaron.org>
Date: Tue, 22 Mar 2011 09:51:18 -0700
To: Ojan Vafai <ojan@chromium.org>
Cc: "www-style@w3.org" <www-style@w3.org>, David Hyatt <hyatt@apple.com>, koivisto@iki.fi
Message-ID: <20110322165118.GA21247@pickering.dbaron.org>
On Tuesday 2011-03-22 18:18 +1100, Ojan Vafai wrote:
> For now, WebKit's implementation of :any is following Mozilla's lead and
> only allowing simple selectors. I don't see any need for this restriction.
> Are there any objections to allowing all selectors?
> 
> I see a similar discussion has happend for :not and that there seemed to be
> agreement that we'd change :not in Selectors 4 to not restrict to simple
> selectors.*

FWIW, the restrictions on the two are actually different.

The arguments to :-moz-any() are what CSS2.1 calls a simple selector
and what css3-selectors calls a sequence of simple selectors.

The argument to :not() is what CSS2.1 calls a component of a simple
selector and what css3-selectors calls a simple selector.

So there are a bunch of options for what we could change.  We could:
 * change :not() to accept what CSS2.1 calls a simple selector
   and what css3-selectors calls a sequence of simple selectors.
 * change either to accept a selector (which implicitly makes :any()
   take a group of selectors, since it's comma operator is
   essentially the same as selector grouping)
 * change :not() to accept a group of selectors

(I regret not formally objecting to the shifts in terminology.)

-David

-- 
L. David Baron                                 http://dbaron.org/
Mozilla Corporation                       http://www.mozilla.com/
Received on Tuesday, 22 March 2011 16:52:03 GMT

This archive was generated by hypermail 2.3.1 : Tuesday, 26 March 2013 17:20:38 GMT