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

[css-variables] Serialization of custom properties vs. comments

From: Simon Sapin <simon.sapin@exyr.org>
Date: Sun, 09 Jun 2013 14:44:56 +0100
Message-ID: <51B486D8.9000606@exyr.org>
To: www-style@w3.org
Hi,

I think that section 4.1.1 Serializing Custom Properties should require 
that the serialization "round-trips". That is, tokenizing it again 
should give the same sequence of tokens.

In particular, this requires either preserving all CSS comments and 
their position when parsing, or inserting comments during serialization 
between "problematic" pairs of of tokens. For example, the following 
tokenizes as two consecutive identifiers without intervening whitespace:

     solid/**/green

They would become a single identifier if serialized naively.

Syntax 3 has a Serialization section about this:
http://dev.w3.org/csswg/css-syntax/#serialization

-- 
Simon Sapin
Received on Sunday, 9 June 2013 21:42:24 UTC

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