Fix missing space at end of self-closing SVG tags when last attribute is unquoted

This commit is contained in:
Wilson Lin 2020-07-04 15:58:35 +10:00
commit 38084e2894

View file

@ -191,6 +191,10 @@ pub fn process_tag(proc: &mut Processor, ns: Namespace, mut prev_sibling_closing
if is_void_tag {
proc.write_slice(b">");
} else {
if let Some(AttrType::Unquoted) = last_attr_type {
// Prevent `/` from being part of the value.
proc.write(b' ');
};
proc.write_slice(b"/>");
};
};