mirror of
https://github.com/servo/servo.git
synced 2025-06-18 22:34:30 +01:00
Prevent ' ' from stripping as whitespace
This commit is contained in:
parent
65191b0d63
commit
327e1e20a9
3 changed files with 7 additions and 5 deletions
|
@ -43,6 +43,7 @@ use style::ComputedValues;
|
|||
use servo_util::namespace;
|
||||
use servo_util::url::parse_url;
|
||||
use servo_util::url::is_image_data;
|
||||
use servo_util::str::is_whitespace_not_nbsp;
|
||||
|
||||
use extra::url::Url;
|
||||
use extra::arc::Arc;
|
||||
|
@ -724,10 +725,7 @@ impl<'ln> NodeUtils for ThreadSafeLayoutNode<'ln> {
|
|||
match self.type_id() {
|
||||
TextNodeTypeId => {
|
||||
unsafe {
|
||||
if !self.with_text(|text| text.characterdata
|
||||
.data
|
||||
.chars()
|
||||
.all(|c| c.is_whitespace())) {
|
||||
if !self.with_text(|text| is_whitespace_not_nbsp(text.characterdata.data)) {
|
||||
return false
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue