Core: rnotwhite -> rhtmlnotwhite and jQuery.trim -> stripAndCollapse

- Renames and changes rnotwhite to focus on HTML whitespace chars
- Change internal use of jQuery.trim to more accurate strip and collapse
- Adds tests to ensure HTML space characters are retained where valid
- Doesn't add tests where the difference is inconsequential and
  existing tests are adequate.

Fixes gh-3003
Fixes gh-3072
Close gh-3316
This commit is contained in:
Timmy Willison
2016-09-12 12:32:02 -04:00
parent 2d4f53416e
commit 3bbcce68d7
15 changed files with 121 additions and 51 deletions

View File

@@ -2,3 +2,4 @@
<div class="user">This is a user</div>
<div class="teacher">This is a teacher</div>
<div id="superuser">This is a superuser</div>
<div id="whitespace\xA0">This is a superuser with non-HTML whitespace</div>