Re: STYLE_SHEETS_USE test

Hi Abel

We jumped through a couple of hoops of fire around this subject possibly 
during LC-1 or LC-2 (the mobileOK Jurassic Period, perhaps). As far as I 
can recall the question was around exactly what is meant by "valid 
CSS1". This is particularly fraught since CSS is by design open-ended so 
outside of the syntax requiring certain combinations of valid tokens and 
punctuation, almost Anything Goes [1].

Consequently, we have the definition of valid CSS under 2.4.8:

     A resource is considered a valid CSS resource if it conforms to the 
grammar defined in [CSS], Appendix B (see note below), except that 
@media at-rules, which are not part of the grammar, are allowed and are 
not considered invalid. The presence of at-rules, properties or values 
or combinations of properties and values that are not specified in [CSS] 
does not constitute a validity failure for CSS. See 3.21 
STYLE_SHEETS_USE for treatment of such values. In addition, the @media 
at-rule and the presentation media list for the @import at-rule are 
taken into account when evaluating CSS.

[I've just  spotted that the clause "see note below" is a dangling 
reference and needs to be removed.]

So I think what is happening here is that the checker CSS Validation 
that is being carried out is actually stricter than that implied by 
CONTENT_FORMAT_SUPPORT and is potentially mis-reporting inappropriate 
combinations of properties and values as failures under that heading. 
They should in fact be reported under STYLE_SHEETS_USE.

Note particularly that it is not invalid to use properties that are not 
known in CSS1, e.g.

klingon {foo: bar;
     distance: 3light-years;
}

is valid, though it contains properties values and units that are not 
defined in CSS1.

Hence the warns rather than the failures in STYLE_SHEETS_USE.

Jo


[1] http://en.wikipedia.org/wiki/Anything_Goes_%28song%29



On 04/07/2008 09:17, Abel Rionda wrote:
> Hi,
> 
> While we were reviewing the test implementation status in checker code,
> we found out some checks 
> of STYLE_SHEETS_USE regarding CSS values that we would like to comment
> [1]:
> 
> [begin STYLE_SHEETS_USE fragment]
> 
> If the CSS Style contains a property with a value that is inappropriate
> to it, warn
> If the CSS Style contains a property with a value that requires a unit
> or a percentage:
>       If the unit (or percentage) is not present, warn
>       If the unit (or percentage) is inappropriate to the value, warn
> 
> [end STYLE_SHEETS_USE fragment]
> 
> All these checks are already made during grammar validation test
> (CONTENT_FORMAT_SUPPORT) and they would raise a *FAIL* (while in
> STYLE_SHEETS_USE at most we would get a *warn*)
> We do not see any benefit of this duplicity and, furthermore, due to
> they raise different level errors, it might lead the user to confusion.
> 
> 
> Regards,
> 
> Abel.
> 
> [1]
> http://www.w3.org/TR/2008/WD-mobileOK-basic10-tests-20080610/#STYLE_SHEE
> TS_USE
> 

Received on Friday, 4 July 2008 09:01:21 UTC