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

[css-variables][css-conditional] bad-string and bad-url tokens in non-custom properties that reference variables

From: Cameron McCormack <cam@mcc.id.au>
Date: Mon, 26 Aug 2013 16:58:11 +1000
Message-ID: <521AFC83.4000600@mcc.id.au>
To: www-style list <www-style@w3.org>
<bad-string> and <bad-url> tokens are disallowed in <any-value>, which 
is used as the value for custom properties and also as the fallback for 
variable references.  But they are not disallowed at the top level of a 
non-custom property that has variable references (and thus invokes the 
"property value containing a variable must be assumed to be valid at 
parse time" requirement).  So:

   @supports (color: var(a, "
             ))                         { ... fails ... }
   @supports (color: var(a, url("b" c)) { ... fails ... }
   @supports (var-a: "
             )                          { ... fails ... }
   @supports (var-a: url("b" c))        { ... fails ... }

But:

   @supports (color: var(a) "
             )                          { ... succeeds ... }
   @supports (color: var(a) url("b" c)) { ... succeeds ... }

Should we make these fail too?
Received on Monday, 26 August 2013 06:58:46 UTC

This archive was generated by hypermail 2.3.1 : Monday, 26 August 2013 06:58:49 UTC