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

Re: List selector and class attribute

From: Allan Sandfeld Jensen <kde@carewolf.com>
Date: Thu, 1 Mar 2007 07:47:01 +0100
To: Ian Hickson <ian@hixie.ch>
Cc: www-style@w3.org
Message-Id: <200703010747.01639.kde@carewolf.com>

On Thursday 01 March 2007 02:45, you wrote:
> On Wed, 23 Mar 2005, Allan Sandfeld Jensen wrote:
> > On Tuesday 22 March 2005 02:54, Ian Hickson wrote:
> > > On Mon, 21 Mar 2005, Allan Sandfeld Jensen wrote:
> > > > 	Or should HTML attributes be white-space transformed so only
> > > > spaces remain.
> > >
> > > This actually should already happen. Per SGML parsing rules, U+000A,
> > > U+000D, and U+0020 all either get stripped or turn into U+0020.
> >
> > Thanks, I finally found it. Looking up standards that are not fully open
> > and cost money sucks. Hopefully this detail can be added to the appendix
> > of HTML in next revision?
> Actually for compatibility with existing browsers, the above requirement
> has been dropped in the HTML5 parser specification. U+000D now turns into
> U+000A, but U+000A and U+0020 are preserved in quoted attributes.
>    http://www.whatwg.org/specs/web-apps/current-work/#attribute2
> From the WHATWG "replying to old e-mails everyone has forgotten about"
> department,

Yes I know. Of course the unspoken consequence of compatible attribute parsing 
is that CSS list selector can accept new-lines separated classes.

This way HTML5 needs the following update in CSS 2.1:

s/space/whitespace/ on

Match when the element's "att" attribute value is a space-separated list   
of "words", one of which is exactly "val". If this selector is used, the 
words in the value must not contain spaces (since they are separated by 

Note: If an element has multiple class attributes, their values must be 
concatenated with spaces between the values before searching for the class. 
As of this time the working group is not aware of any manner in which this 
situation can be reached, however, so this behavior is explicitly 
non-normative in this specification.

Received on Thursday, 1 March 2007 06:47:27 UTC

This archive was generated by hypermail 2.3.1 : Monday, 2 May 2016 14:27:28 UTC