W3C home > Mailing lists > Public > www-style@w3.org > August 2015

Re: [selectors] feedback

From: Anne van Kesteren <annevk@annevk.nl>
Date: Thu, 27 Aug 2015 08:06:56 +0200
Message-ID: <CADnb78gKER2+voPzagMhQgV7wLJvsw-jrcak7xyyKqUtapHYkw@mail.gmail.com>
To: fantasai <fantasai.lists@inkedblade.net>
Cc: "Tab Atkins Jr." <jackalmage@gmail.com>, "www-style@w3.org" <www-style@w3.org>, Robin Berjon <robin@w3.org>
On Thu, Aug 27, 2015 at 3:41 AM, fantasai <fantasai.lists@inkedblade.net> wrote:
> Well, it would be confusing if the behavior was implied from how
> we interpret the tree. But it's not: it's explicitly called out:
>
>   "Non-element nodes (e.g. text between elements) are ignored when
>    considering the adjacency of elements."
>
> As I mentioned, equivalent text has been there since CSS Level 2.

I know, but this text doesn't always apply. Otherwise :empty would not
work. Suddenly with :empty you operate on a different tree. It seems
you also ignored my comment about Shadow DOM.


> How about instead of providing a algorithm for finding matches in a
> subtree, we used "match" as the hook, and DOM provides the list of
> things that need to be evaluated against the selector?

Doesn't work for :empty. And still doesn't help with pseudo-elements
and such as the input for matching those would be the same.


-- 
https://annevankesteren.nl/
Received on Thursday, 27 August 2015 06:07:28 UTC

This archive was generated by hypermail 2.3.1 : Thursday, 27 August 2015 06:07:29 UTC