Don't armor french spaces before punctuation followed by word characters
authorC. Scott Ananian <cscott@cscott.net>
Thu, 21 Jun 2018 15:36:07 +0000 (11:36 -0400)
committerC. Scott Ananian <cscott@cscott.net>
Tue, 26 Jun 2018 16:51:48 +0000 (12:51 -0400)
commitbe266087b47cc5a6dee48bffc89e58d232e59890
treef3640893409d247675fc8949b5aab546a2a4a24e
parente1990c6f0e1edc0379e2626c6e6ff5f0a2511233
Don't armor french spaces before punctuation followed by word characters

This makes Sanitizer::armorFrenchSpaces() more selective about where it
inserts &nbsp;, avoiding the need to protect common "not actually French"
cases like `color: red !important` and `foo :bar`.

We also added the single-guillemet to the rules, to accomodate Swiss French.

Bug: T197902
Change-Id: I42e747f17c17c1513fec96cdd2d3285da7da05a4
includes/parser/Sanitizer.php
tests/parser/parserTests.txt