W3C home > Mailing lists > Public > www-style@w3.org > June 2013

Re: [css3-cascade] Rolling back the cascade and 'default'

From: Tab Atkins Jr. <jackalmage@gmail.com>
Date: Mon, 10 Jun 2013 03:20:51 +0900
Message-ID: <CAAWBYDBXjGzBBVRJZNjNpA3ZLnOTpVRG=K1LoJfmbR4_STeRmA@mail.gmail.com>
To: fantasai <fantasai.lists@inkedblade.net>
Cc: "www-style@w3.org" <www-style@w3.org>
On Sun, Jun 9, 2013 at 6:43 PM, fantasai <fantasai.lists@inkedblade.net> wrote:
> I was just thinking about some of dbaron's comments on 'default' from
> the F2F, specifically about whether the two user levels (normal and
> !important) were grouped together for the purpose of cascade rollback.
>
> Currently in the spec they're not, but thinking about it I realize
> that perhaps that's not reasonable.
>
> Consider in the user style sheet:
>   :link { color: default; }            /* resets to UA default color */
>   :link { color: default !important; } /* says to use the author's choice */
>
> The declaration substantially changes meaning when we add !important
> here, and that probably doesn't make much sense. Thoughts?

It seems difficult to tell what the intent is.  Unlike
author-important, which can just be treated like a fourth level of
specificity, higher than #id, user-important is substantially
different from user.  User-level just sets defaults, which are used
when the author doesn't set anything else; user-important sets
*mandates*, which can't be overridden by the author at all.  It seems
reasonable that a user may want to reset their "mandates" without
resetting their "defaults".

On the other hand, it also seems reasonable that a user might want to
use the "default" semantics to indicate that they really, really want
the user-agent defaults for something, such that it should wipe out
*everything* between user and user-important, including the author
levels.  This preserves dbaron's desired invariant that the dropped
origins are contiguous.

So, dunno which might be more reasonable.

~TJ
Received on Sunday, 9 June 2013 18:21:38 UTC

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