Re: Minor bug in CSS Validator

> On 2 Sep 2022, at 06:24, Lars Noodén <lars.nooden@gmx.com> wrote:

Dear Lars,

> 
> Thanks for having the CSS Validator available, it helps a lot.
> 
> In the process of debugging a larger stylesheet, I notice that the
> validator seems to have trouble with some characters in the content:
> selector.  For example, the following always generates an error.
> 
> p:after {
>  content: " 🡆 ";
> }
> 
> If the Unicode is removed and replaced with something ASCII, then the
> error goes away.  I would have expected the validator to allow even
> Unicode inside the quotes.

I note that you are using the validator via upload, in that case the charset is not defined as it could be, served by a web server.
Do you have a @charset defined? [2]
When I try you example via text input, it is refused as ascii/iso-8859, etc… but if I add the proper @charset rule, it is processed without any issue.
It is not to say that you MUST always use @charset, especially as it might be inferred by the way you are serving this, but it might be the reason you have that issue when using the “by upload” method.
Cheers,

[2] https://developer.mozilla.org/en-US/docs/Web/CSS/@charset

> 
> Regards,
> Lars
> 
> 
> [1] https://jigsaw.w3.org/css-validator/#validate-by-upload
> 
> 
> 

-- 
Baroula que barouleras, au tiéu toujou t'entourneras.

        ~~Yves

Received on Friday, 2 September 2022 12:42:45 UTC