Re: Expected behaviour of quotation marks

> On Apr 7, 2016, at 23:39, ishida@w3.org wrote:


> Perhaps what we need is a CSS rule that says, 'If you're not inside a q element, then set the quotes per the language outside the quote; but if you are inside, ignore the language info.'

Sounds right.

> I'm not quite sure how to say that in selector-speak yet.

I believe this is the way to right it:

:lang(fr) > *:not(q *) { quotes: "« " " »" "‹ " " ›" }
:lang(en) > *:not(q *) { quotes: "“" "”" "‘" "’" }

Here's a demo:
  http://jsbin.com/savatoqala/edit?html,css,output

This only seems to Safari (not Chrome) implements :not() well enough to support this, but I believe it is correct by spec, and it does work in Safari.

 - Florian

Received on Friday, 8 April 2016 00:58:01 UTC