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

Re: Case Sensitivity Issue and CSSOM

From: John Daggett <jdaggett@mozilla.com>
Date: Wed, 23 Jan 2013 18:13:20 -0800 (PST)
To: www-style list <www-style@w3.org>
Cc: WWW International <www-international@w3.org>
Message-ID: <711067899.308329.1358993600519.JavaMail.root@mozilla.com>
Tab Atkins wrote:

> > Given this, I'm leaning towards Richard Ishida's (?) suggestion
> > that we leave user-defined idents as case-sensitive and just
> > grandfather in any CSS-defined keywords as computing to their
> > lowercase variants.
> How does this work with custom property names?  Do we require that
> their prefix be literally "var-", so "VAR-FOO" is an invalid
> property and thrown away at parse time?

The same way counter(FOO) vs. COUNTER(FOO) is handled today.  The
'counter' portion is a CSS keyword and the FOO part is a user-defined
ident.  Same for the variable syntax, 'var-' is a keyword and follows
the rules for matching keywords, while 'FOO' is a user-defined ident
that follows the rules for user defined idents.

The fact that authors may not see 'var-foo' as one part keyword, one
part user-defined ident is one of the weaknesses of the 'var-' syntax
that we've just decided to accept.  But if someone is clever enough
to use variables in their CSS, they can figure out casing rules I'm


Received on Thursday, 24 January 2013 02:13:48 UTC

This archive was generated by hypermail 2.4.0 : Friday, 25 March 2022 10:08:25 UTC