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

Re: Domain selectors

From: Jens Oliver Meiert <jens@meiert.com>
Date: Mon, 9 Mar 2015 20:14:06 +0100
Message-ID: <CAJ0g8QSuOuo_m3tgO9w6L-V5wf8TNqzrkp+7Eh3gf5MLZp63ow@mail.gmail.com>
To: Marat Tanalin <mtanalin@yandex.ru>
Cc: "L. David Baron" <dbaron@dbaron.org>, W3C WWW Style <www-style@w3.org>
> As an alternative selector syntax for your purpose, a function could be used
> instead of the attribute-selector syntax you've proposed:
>
>     ::domain("example.com") .foo {
>         /* Domain-specific styles for elements
>            with the `foo` class. */
>     }
>
> But this does not seem to have serious advantages (other than just
> somewhat simpler syntax thanks to less braces) over an at-rule like
> `@document`:
>
>     @document domain("example.com") {
>         .foo {
>             /* Domain-specific styles for elements
>                with the `foo` class. */
>         }
>     }

I’d prefer ::domain over @document, but I’d wish we pushed harder for
simplicity. Hence, is that all as simple as we could get it? Why would
[host=] (or domain, document, or perhaps url) be so objectionable?

-- 
Jens Oliver Meiert
http://meiert.com/en/

✎ The Little Book of HTML/CSS Frameworks: http://meiert.com/frameworks
Received on Monday, 9 March 2015 19:14:54 UTC

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