mirror of
https://github.com/servo/servo.git
synced 2025-08-03 04:30:10 +01:00
Properly mark application/xhtml+xml documents as XML
For this to work, we must remove the unimplemented!() call in Element::parse_fragment because all the tests rely on setting innerHTML.
This commit is contained in:
parent
0c64bd766a
commit
c1bdd3d5ce
8 changed files with 9 additions and 136 deletions
|
@ -1278,12 +1278,8 @@ impl Element {
|
|||
pub fn parse_fragment(&self, markup: DOMString) -> Fallible<Root<DocumentFragment>> {
|
||||
// Steps 1-2.
|
||||
let context_document = document_from_node(self);
|
||||
let new_children = if context_document.is_html_document() {
|
||||
ServoParser::parse_html_fragment(self, markup)
|
||||
} else {
|
||||
// FIXME: XML case
|
||||
unimplemented!()
|
||||
};
|
||||
// TODO(#11995): XML case.
|
||||
let new_children = ServoParser::parse_html_fragment(self, markup);
|
||||
// Step 3.
|
||||
let fragment = DocumentFragment::new(&context_document);
|
||||
// Step 4.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue