+ "data": "<!doctype html><main><p>foo</main>bar",
+ "errors": [],
+ "document": {
+ "props": {
+ "tags": {
+ "html": true,
+ "head": true,
+ "body": true,
+ "main": true,
+ "p": true
+ },
+ "doctype": true
+ },
+ "tree": [
+ {
+ "doctype": "html"
+ },
+ {
+ "tag": "html",
+ "children": [
+ {
+ "tag": "head"
+ },
+ {
+ "tag": "body",
+ "children": [
+ {
+ "tag": "main",
+ "children": [
+ {
+ "tag": "p",
+ "children": [
+ {
+ "text": "foo"
+ }
+ ]
+ }
+ ]
+ },
+ {
+ "text": "bar"
+ }
+ ]
+ }
+ ]
+ }
+ ],
+ "html": "<!DOCTYPE html><html><head></head><body><main><p>foo</p></main>bar</body></html>",
+ "noQuirksBodyHtml": "<main><p>foo</p></main>bar"
+ }
+ },
+ {
+ "data": "<!DOCTYPE html>xxx<svg><x><g><a><main><b>",
+ "errors": [
+ " * (1,42) unexpected HTML-like start tag token in foreign content",
+ " * (1,42) unexpected end of file"
+ ],
+ "document": {
+ "props": {
+ "tags": {
+ "html": true,
+ "head": true,
+ "body": true,
+ "svg svg": true,
+ "svg x": true,
+ "svg g": true,
+ "svg a": true,
+ "svg main": true,
+ "b": true
+ },
+ "doctype": true
+ },
+ "tree": [
+ {
+ "doctype": "html"
+ },
+ {
+ "tag": "html",
+ "children": [
+ {
+ "tag": "head"
+ },
+ {
+ "tag": "body",
+ "children": [
+ {
+ "text": "xxx"
+ },
+ {
+ "tag": "svg",
+ "ns": "http://www.w3.org/2000/svg",
+ "children": [
+ {
+ "tag": "x",
+ "ns": "http://www.w3.org/2000/svg",
+ "children": [
+ {
+ "tag": "g",
+ "ns": "http://www.w3.org/2000/svg",
+ "children": [
+ {
+ "tag": "a",
+ "ns": "http://www.w3.org/2000/svg",
+ "children": [
+ {
+ "tag": "main",
+ "ns": "http://www.w3.org/2000/svg"
+ }
+ ]
+ }
+ ]
+ }
+ ]
+ }
+ ]
+ },
+ {
+ "tag": "b"
+ }
+ ]
+ }
+ ]
+ }
+ ],
+ "html": "<!DOCTYPE html><html><head></head><body>xxx<svg><x><g><a><main></main></a></g></x></svg><b></b></body></html>",
+ "noQuirksBodyHtml": "xxx<svg><x><g><a><main><b></b></main></a></g></x></svg>"
+ }
+ }
+ ],
+ "math.dat": [
+ {
+ "data": "<math><tr><td><mo><tr>",
+ "errors": [],
+ "fragment": {
+ "name": "td"
+ },
+ "document": {
+ "props": {
+ "tags": {
+ "math math": true,
+ "math tr": true,
+ "math td": true,
+ "math mo": true
+ }
+ },
+ "tree": [
+ {
+ "tag": "math",
+ "ns": "http://www.w3.org/1998/Math/MathML",
+ "children": [
+ {
+ "tag": "tr",
+ "ns": "http://www.w3.org/1998/Math/MathML",
+ "children": [
+ {
+ "tag": "td",
+ "ns": "http://www.w3.org/1998/Math/MathML",
+ "children": [
+ {
+ "tag": "mo",
+ "ns": "http://www.w3.org/1998/Math/MathML"
+ }
+ ]
+ }
+ ]
+ }
+ ]
+ }
+ ],
+ "html": "<math><tr><td><mo></mo></td></tr></math>",
+ "noQuirksBodyHtml": "<math><tr><td><mo></mo></td></tr></math>"
+ }
+ },
+ {
+ "data": "<math><tr><td><mo><tr>",
+ "errors": [],
+ "fragment": {
+ "name": "tr"
+ },
+ "document": {
+ "props": {
+ "tags": {
+ "math math": true,
+ "math tr": true,
+ "math td": true,
+ "math mo": true
+ }
+ },
+ "tree": [
+ {
+ "tag": "math",
+ "ns": "http://www.w3.org/1998/Math/MathML",
+ "children": [
+ {
+ "tag": "tr",
+ "ns": "http://www.w3.org/1998/Math/MathML",
+ "children": [
+ {
+ "tag": "td",
+ "ns": "http://www.w3.org/1998/Math/MathML",
+ "children": [
+ {
+ "tag": "mo",
+ "ns": "http://www.w3.org/1998/Math/MathML"
+ }
+ ]
+ }
+ ]
+ }
+ ]
+ }
+ ],
+ "html": "<math><tr><td><mo></mo></td></tr></math>",
+ "noQuirksBodyHtml": "<math><tr><td><mo></mo></td></tr></math>"
+ }
+ },
+ {
+ "data": "<math><thead><mo><tbody>",
+ "errors": [],
+ "fragment": {
+ "name": "thead"
+ },
+ "document": {
+ "props": {
+ "tags": {
+ "math math": true,
+ "math thead": true,
+ "math mo": true
+ }
+ },
+ "tree": [
+ {
+ "tag": "math",
+ "ns": "http://www.w3.org/1998/Math/MathML",
+ "children": [
+ {
+ "tag": "thead",
+ "ns": "http://www.w3.org/1998/Math/MathML",
+ "children": [
+ {
+ "tag": "mo",
+ "ns": "http://www.w3.org/1998/Math/MathML"
+ }
+ ]
+ }
+ ]
+ }
+ ],
+ "html": "<math><thead><mo></mo></thead></math>",
+ "noQuirksBodyHtml": "<math><thead><mo></mo></thead></math>"
+ }
+ },
+ {
+ "data": "<math><tfoot><mo><tbody>",
+ "errors": [],
+ "fragment": {
+ "name": "tfoot"
+ },
+ "document": {
+ "props": {
+ "tags": {
+ "math math": true,
+ "math tfoot": true,
+ "math mo": true
+ }
+ },
+ "tree": [
+ {
+ "tag": "math",
+ "ns": "http://www.w3.org/1998/Math/MathML",
+ "children": [
+ {
+ "tag": "tfoot",
+ "ns": "http://www.w3.org/1998/Math/MathML",
+ "children": [
+ {
+ "tag": "mo",
+ "ns": "http://www.w3.org/1998/Math/MathML"
+ }
+ ]
+ }
+ ]
+ }
+ ],
+ "html": "<math><tfoot><mo></mo></tfoot></math>",
+ "noQuirksBodyHtml": "<math><tfoot><mo></mo></tfoot></math>"
+ }
+ },
+ {
+ "data": "<math><tbody><mo><tfoot>",
+ "errors": [],
+ "fragment": {
+ "name": "tbody"
+ },
+ "document": {
+ "props": {
+ "tags": {
+ "math math": true,
+ "math tbody": true,
+ "math mo": true
+ }
+ },
+ "tree": [
+ {
+ "tag": "math",
+ "ns": "http://www.w3.org/1998/Math/MathML",
+ "children": [
+ {
+ "tag": "tbody",
+ "ns": "http://www.w3.org/1998/Math/MathML",
+ "children": [
+ {
+ "tag": "mo",
+ "ns": "http://www.w3.org/1998/Math/MathML"
+ }
+ ]
+ }
+ ]
+ }
+ ],
+ "html": "<math><tbody><mo></mo></tbody></math>",
+ "noQuirksBodyHtml": "<math><tbody><mo></mo></tbody></math>"
+ }
+ },
+ {
+ "data": "<math><tbody><mo></table>",
+ "errors": [],
+ "fragment": {
+ "name": "tbody"
+ },
+ "document": {
+ "props": {
+ "tags": {
+ "math math": true,
+ "math tbody": true,
+ "math mo": true
+ }
+ },
+ "tree": [
+ {
+ "tag": "math",
+ "ns": "http://www.w3.org/1998/Math/MathML",
+ "children": [
+ {
+ "tag": "tbody",
+ "ns": "http://www.w3.org/1998/Math/MathML",
+ "children": [
+ {
+ "tag": "mo",
+ "ns": "http://www.w3.org/1998/Math/MathML"
+ }
+ ]
+ }
+ ]
+ }
+ ],
+ "html": "<math><tbody><mo></mo></tbody></math>",
+ "noQuirksBodyHtml": "<math><tbody><mo></mo></tbody></math>"
+ }
+ },
+ {
+ "data": "<math><thead><mo></table>",
+ "errors": [],
+ "fragment": {
+ "name": "tbody"
+ },
+ "document": {
+ "props": {
+ "tags": {
+ "math math": true,
+ "math thead": true,
+ "math mo": true
+ }
+ },
+ "tree": [
+ {
+ "tag": "math",
+ "ns": "http://www.w3.org/1998/Math/MathML",
+ "children": [
+ {
+ "tag": "thead",
+ "ns": "http://www.w3.org/1998/Math/MathML",
+ "children": [
+ {
+ "tag": "mo",
+ "ns": "http://www.w3.org/1998/Math/MathML"
+ }
+ ]
+ }
+ ]
+ }
+ ],
+ "html": "<math><thead><mo></mo></thead></math>",
+ "noQuirksBodyHtml": "<math><thead><mo></mo></thead></math>"
+ }
+ },
+ {
+ "data": "<math><tfoot><mo></table>",
+ "errors": [],
+ "fragment": {
+ "name": "tbody"
+ },
+ "document": {
+ "props": {
+ "tags": {
+ "math math": true,
+ "math tfoot": true,
+ "math mo": true
+ }
+ },
+ "tree": [
+ {
+ "tag": "math",
+ "ns": "http://www.w3.org/1998/Math/MathML",
+ "children": [
+ {
+ "tag": "tfoot",
+ "ns": "http://www.w3.org/1998/Math/MathML",
+ "children": [
+ {
+ "tag": "mo",
+ "ns": "http://www.w3.org/1998/Math/MathML"
+ }
+ ]
+ }
+ ]
+ }
+ ],
+ "html": "<math><tfoot><mo></mo></tfoot></math>",
+ "noQuirksBodyHtml": "<math><tfoot><mo></mo></tfoot></math>"
+ }
+ }
+ ],
+ "menuitem-element.dat": [
+ {
+ "data": "<menuitem>",
+ "errors": [
+ "10: Start tag seen without seeing a doctype first. Expected “<!DOCTYPE html>”."
+ ],
+ "document": {
+ "props": {
+ "tags": {
+ "html": true,
+ "head": true,
+ "body": true,
+ "menuitem": true
+ }
+ },
+ "tree": [
+ {
+ "tag": "html",
+ "children": [
+ {
+ "tag": "head"
+ },
+ {
+ "tag": "body",
+ "children": [
+ {
+ "tag": "menuitem"
+ }
+ ]
+ }
+ ]
+ }
+ ],
+ "html": "<html><head></head><body><menuitem></menuitem></body></html>",
+ "noQuirksBodyHtml": "<menuitem></menuitem>"
+ }
+ },
+ {
+ "data": "</menuitem>",
+ "errors": [
+ "11: End tag seen without seeing a doctype first. Expected “<!DOCTYPE html>”.",
+ "11: Stray end tag “menuitem”."
+ ],
+ "document": {
+ "props": {
+ "tags": {
+ "html": true,
+ "head": true,
+ "body": true
+ }
+ },
+ "tree": [
+ {
+ "tag": "html",
+ "children": [
+ {
+ "tag": "head"
+ },
+ {
+ "tag": "body"
+ }
+ ]
+ }
+ ],
+ "html": "<html><head></head><body></body></html>",
+ "noQuirksBodyHtml": ""
+ }
+ },
+ {
+ "data": "<!DOCTYPE html><body><menuitem>A",
+ "errors": [],
+ "document": {
+ "props": {
+ "tags": {
+ "html": true,
+ "head": true,
+ "body": true,
+ "menuitem": true
+ },
+ "doctype": true
+ },
+ "tree": [
+ {
+ "doctype": "html"
+ },
+ {
+ "tag": "html",
+ "children": [
+ {
+ "tag": "head"
+ },
+ {
+ "tag": "body",
+ "children": [
+ {
+ "tag": "menuitem",
+ "children": [
+ {
+ "text": "A"
+ }
+ ]
+ }
+ ]
+ }
+ ]
+ }
+ ],
+ "html": "<!DOCTYPE html><html><head></head><body><menuitem>A</menuitem></body></html>",
+ "noQuirksBodyHtml": "<menuitem>A</menuitem>"
+ }
+ },
+ {
+ "data": "<!DOCTYPE html><body><menuitem>A<menuitem>B",
+ "errors": [],
+ "document": {
+ "props": {
+ "tags": {
+ "html": true,
+ "head": true,
+ "body": true,
+ "menuitem": true
+ },
+ "doctype": true
+ },
+ "tree": [
+ {
+ "doctype": "html"
+ },
+ {
+ "tag": "html",
+ "children": [
+ {
+ "tag": "head"
+ },
+ {
+ "tag": "body",
+ "children": [
+ {
+ "tag": "menuitem",
+ "children": [
+ {
+ "text": "A"
+ }
+ ]
+ },
+ {
+ "tag": "menuitem",
+ "children": [
+ {
+ "text": "B"
+ }
+ ]
+ }
+ ]
+ }
+ ]
+ }
+ ],
+ "html": "<!DOCTYPE html><html><head></head><body><menuitem>A</menuitem><menuitem>B</menuitem></body></html>",
+ "noQuirksBodyHtml": "<menuitem>A</menuitem><menuitem>B</menuitem>"
+ }
+ },
+ {
+ "data": "<!DOCTYPE html><body><menuitem>A<menu>B</menu>",
+ "errors": [],
+ "document": {
+ "props": {
+ "tags": {
+ "html": true,
+ "head": true,
+ "body": true,
+ "menuitem": true,
+ "menu": true
+ },
+ "doctype": true
+ },
+ "tree": [
+ {
+ "doctype": "html"
+ },
+ {
+ "tag": "html",
+ "children": [
+ {
+ "tag": "head"
+ },
+ {
+ "tag": "body",
+ "children": [
+ {
+ "tag": "menuitem",
+ "children": [
+ {
+ "text": "A"
+ }
+ ]
+ },
+ {
+ "tag": "menu",
+ "children": [
+ {
+ "text": "B"
+ }
+ ]
+ }
+ ]
+ }
+ ]
+ }
+ ],
+ "html": "<!DOCTYPE html><html><head></head><body><menuitem>A</menuitem><menu>B</menu></body></html>",
+ "noQuirksBodyHtml": "<menuitem>A</menuitem><menu>B</menu>"
+ }
+ },
+ {
+ "data": "<!DOCTYPE html><body><menuitem>A<hr>B",
+ "errors": [],
+ "document": {
+ "props": {
+ "tags": {
+ "html": true,
+ "head": true,
+ "body": true,
+ "menuitem": true,
+ "hr": true
+ },
+ "doctype": true
+ },
+ "tree": [
+ {
+ "doctype": "html"
+ },
+ {
+ "tag": "html",
+ "children": [
+ {
+ "tag": "head"
+ },
+ {
+ "tag": "body",
+ "children": [
+ {
+ "tag": "menuitem",
+ "children": [
+ {
+ "text": "A"
+ }
+ ]
+ },
+ {
+ "tag": "hr"
+ },
+ {
+ "text": "B"
+ }
+ ]
+ }
+ ]
+ }
+ ],
+ "html": "<!DOCTYPE html><html><head></head><body><menuitem>A</menuitem><hr>B</body></html>",
+ "noQuirksBodyHtml": "<menuitem>A</menuitem><hr>B"
+ }
+ },
+ {
+ "data": "<!DOCTYPE html><li><menuitem><li>",
+ "errors": [],
+ "document": {
+ "props": {
+ "tags": {
+ "html": true,
+ "head": true,
+ "body": true,
+ "li": true,
+ "menuitem": true
+ },
+ "doctype": true
+ },
+ "tree": [
+ {
+ "doctype": "html"
+ },
+ {
+ "tag": "html",
+ "children": [
+ {
+ "tag": "head"
+ },
+ {
+ "tag": "body",
+ "children": [
+ {
+ "tag": "li",
+ "children": [
+ {
+ "tag": "menuitem"
+ }
+ ]
+ },
+ {
+ "tag": "li"
+ }
+ ]
+ }
+ ]
+ }
+ ],
+ "html": "<!DOCTYPE html><html><head></head><body><li><menuitem></menuitem></li><li></li></body></html>",
+ "noQuirksBodyHtml": "<li><menuitem></menuitem></li><li></li>"
+ }
+ },
+ {
+ "data": "<!DOCTYPE html><menuitem><p></menuitem>x",
+ "errors": [
+ "39: Stray end tag “menuitem”."
+ ],
+ "document": {
+ "props": {
+ "tags": {
+ "html": true,
+ "head": true,
+ "body": true,
+ "menuitem": true,
+ "p": true
+ },
+ "doctype": true
+ },
+ "tree": [
+ {
+ "doctype": "html"
+ },
+ {
+ "tag": "html",
+ "children": [
+ {
+ "tag": "head"
+ },
+ {
+ "tag": "body",
+ "children": [
+ {
+ "tag": "menuitem",
+ "children": [
+ {
+ "tag": "p",
+ "children": [
+ {
+ "text": "x"
+ }
+ ]
+ }
+ ]
+ }
+ ]
+ }
+ ]
+ }
+ ],
+ "html": "<!DOCTYPE html><html><head></head><body><menuitem><p>x</p></menuitem></body></html>",
+ "noQuirksBodyHtml": "<menuitem><p>x</p></menuitem>"
+ }
+ },
+ {
+ "data": "<!DOCTYPE html><p><b></p><menuitem>",
+ "errors": [
+ "25: End tag “p” seen, but there were open elements.",
+ "21: Unclosed element “b”.",
+ "35: End of file seen and there were open elements."
+ ],
+ "document": {
+ "props": {
+ "tags": {
+ "html": true,
+ "head": true,
+ "body": true,
+ "p": true,
+ "b": true,
+ "menuitem": true
+ },
+ "doctype": true
+ },
+ "tree": [
+ {
+ "doctype": "html"
+ },
+ {
+ "tag": "html",
+ "children": [
+ {
+ "tag": "head"
+ },
+ {
+ "tag": "body",
+ "children": [
+ {
+ "tag": "p",
+ "children": [
+ {
+ "tag": "b"
+ }
+ ]
+ },
+ {
+ "tag": "b",
+ "children": [
+ {
+ "tag": "menuitem"
+ }
+ ]
+ }
+ ]
+ }
+ ]
+ }
+ ],
+ "html": "<!DOCTYPE html><html><head></head><body><p><b></b></p><b><menuitem></menuitem></b></body></html>",
+ "noQuirksBodyHtml": "<p><b></b></p><b><menuitem></menuitem></b>"
+ }
+ },
+ {
+ "data": "<!DOCTYPE html><menuitem><asdf></menuitem>x",
+ "errors": [
+ "40: End tag “menuitem” seen, but there were open elements.",
+ "31: Unclosed element “asdf”."
+ ],
+ "document": {
+ "props": {
+ "tags": {
+ "html": true,
+ "head": true,
+ "body": true,
+ "menuitem": true,
+ "asdf": true
+ },
+ "doctype": true
+ },
+ "tree": [
+ {
+ "doctype": "html"
+ },
+ {
+ "tag": "html",
+ "children": [
+ {
+ "tag": "head"
+ },
+ {
+ "tag": "body",
+ "children": [
+ {
+ "tag": "menuitem",
+ "children": [
+ {
+ "tag": "asdf"
+ }
+ ]
+ },
+ {
+ "text": "x"
+ }
+ ]
+ }
+ ]
+ }
+ ],
+ "html": "<!DOCTYPE html><html><head></head><body><menuitem><asdf></asdf></menuitem>x</body></html>",
+ "noQuirksBodyHtml": "<menuitem><asdf></asdf></menuitem>x"
+ }
+ },
+ {
+ "data": "<!DOCTYPE html></menuitem>",
+ "errors": [
+ "26: Stray end tag “menuitem”."
+ ],
+ "document": {
+ "props": {
+ "tags": {
+ "html": true,
+ "head": true,
+ "body": true
+ },
+ "doctype": true
+ },
+ "tree": [
+ {
+ "doctype": "html"
+ },
+ {
+ "tag": "html",
+ "children": [
+ {
+ "tag": "head"
+ },
+ {
+ "tag": "body"
+ }
+ ]
+ }
+ ],
+ "html": "<!DOCTYPE html><html><head></head><body></body></html>",
+ "noQuirksBodyHtml": ""
+ }
+ },
+ {
+ "data": "<!DOCTYPE html><html></menuitem>",
+ "errors": [
+ "26: Stray end tag “menuitem”."
+ ],
+ "document": {
+ "props": {
+ "tags": {
+ "html": true,
+ "head": true,
+ "body": true
+ },
+ "doctype": true
+ },
+ "tree": [
+ {
+ "doctype": "html"
+ },
+ {
+ "tag": "html",
+ "children": [
+ {
+ "tag": "head"
+ },
+ {
+ "tag": "body"
+ }
+ ]
+ }
+ ],
+ "html": "<!DOCTYPE html><html><head></head><body></body></html>",
+ "noQuirksBodyHtml": ""
+ }
+ },
+ {
+ "data": "<!DOCTYPE html><head></menuitem>",
+ "errors": [
+ "26: Stray end tag “menuitem”."
+ ],
+ "document": {
+ "props": {
+ "tags": {
+ "html": true,
+ "head": true,
+ "body": true
+ },
+ "doctype": true
+ },
+ "tree": [
+ {
+ "doctype": "html"
+ },
+ {
+ "tag": "html",
+ "children": [
+ {
+ "tag": "head"
+ },
+ {
+ "tag": "body"
+ }
+ ]
+ }
+ ],
+ "html": "<!DOCTYPE html><html><head></head><body></body></html>",
+ "noQuirksBodyHtml": ""
+ }
+ },
+ {
+ "data": "<!DOCTYPE html><select><menuitem></select>",
+ "errors": [
+ "33: Stray start tag “menuitem”."
+ ],
+ "document": {
+ "props": {
+ "tags": {
+ "html": true,
+ "head": true,
+ "body": true,
+ "select": true
+ },
+ "doctype": true
+ },
+ "tree": [
+ {
+ "doctype": "html"
+ },
+ {
+ "tag": "html",
+ "children": [
+ {
+ "tag": "head"
+ },
+ {
+ "tag": "body",
+ "children": [
+ {
+ "tag": "select"
+ }
+ ]
+ }
+ ]
+ }
+ ],
+ "html": "<!DOCTYPE html><html><head></head><body><select></select></body></html>",
+ "noQuirksBodyHtml": "<select></select>"
+ }
+ },
+ {
+ "data": "<!DOCTYPE html><option><menuitem>",
+ "errors": [],
+ "document": {
+ "props": {
+ "tags": {
+ "html": true,
+ "head": true,
+ "body": true,
+ "option": true,
+ "menuitem": true
+ },
+ "doctype": true
+ },
+ "tree": [
+ {
+ "doctype": "html"
+ },
+ {
+ "tag": "html",
+ "children": [
+ {
+ "tag": "head"
+ },
+ {
+ "tag": "body",
+ "children": [
+ {
+ "tag": "option",
+ "children": [
+ {
+ "tag": "menuitem"
+ }
+ ]
+ }
+ ]
+ }
+ ]
+ }
+ ],
+ "html": "<!DOCTYPE html><html><head></head><body><option><menuitem></menuitem></option></body></html>",
+ "noQuirksBodyHtml": "<option><menuitem></menuitem></option>"
+ }
+ },
+ {
+ "data": "<!DOCTYPE html><menuitem><option>",
+ "errors": [],
+ "document": {
+ "props": {
+ "tags": {
+ "html": true,
+ "head": true,
+ "body": true,
+ "menuitem": true,
+ "option": true
+ },
+ "doctype": true
+ },
+ "tree": [
+ {
+ "doctype": "html"
+ },
+ {
+ "tag": "html",
+ "children": [
+ {
+ "tag": "head"
+ },
+ {
+ "tag": "body",
+ "children": [
+ {
+ "tag": "menuitem",
+ "children": [
+ {
+ "tag": "option"
+ }
+ ]
+ }
+ ]
+ }
+ ]
+ }
+ ],
+ "html": "<!DOCTYPE html><html><head></head><body><menuitem><option></option></menuitem></body></html>",
+ "noQuirksBodyHtml": "<menuitem><option></option></menuitem>"
+ }
+ },
+ {
+ "data": "<!DOCTYPE html><menuitem></body>",
+ "errors": [],
+ "document": {
+ "props": {
+ "tags": {
+ "html": true,
+ "head": true,
+ "body": true,
+ "menuitem": true
+ },
+ "doctype": true
+ },
+ "tree": [
+ {
+ "doctype": "html"
+ },
+ {
+ "tag": "html",
+ "children": [
+ {
+ "tag": "head"
+ },
+ {
+ "tag": "body",
+ "children": [
+ {
+ "tag": "menuitem"
+ }
+ ]
+ }
+ ]
+ }
+ ],
+ "html": "<!DOCTYPE html><html><head></head><body><menuitem></menuitem></body></html>",
+ "noQuirksBodyHtml": "<menuitem></menuitem>"
+ }
+ },
+ {
+ "data": "<!DOCTYPE html><menuitem></html>",
+ "errors": [],
+ "document": {
+ "props": {
+ "tags": {
+ "html": true,
+ "head": true,
+ "body": true,
+ "menuitem": true
+ },
+ "doctype": true
+ },
+ "tree": [
+ {
+ "doctype": "html"
+ },
+ {
+ "tag": "html",
+ "children": [
+ {
+ "tag": "head"
+ },
+ {
+ "tag": "body",
+ "children": [
+ {
+ "tag": "menuitem"
+ }
+ ]
+ }
+ ]
+ }
+ ],
+ "html": "<!DOCTYPE html><html><head></head><body><menuitem></menuitem></body></html>",
+ "noQuirksBodyHtml": "<menuitem></menuitem>"
+ }
+ },
+ {
+ "data": "<!DOCTYPE html><menuitem><p>",
+ "errors": [],
+ "document": {
+ "props": {
+ "tags": {
+ "html": true,
+ "head": true,
+ "body": true,
+ "menuitem": true,
+ "p": true
+ },
+ "doctype": true
+ },
+ "tree": [
+ {
+ "doctype": "html"
+ },
+ {
+ "tag": "html",
+ "children": [
+ {
+ "tag": "head"
+ },
+ {
+ "tag": "body",
+ "children": [
+ {
+ "tag": "menuitem",
+ "children": [
+ {
+ "tag": "p"
+ }
+ ]
+ }
+ ]
+ }
+ ]
+ }
+ ],
+ "html": "<!DOCTYPE html><html><head></head><body><menuitem><p></p></menuitem></body></html>",
+ "noQuirksBodyHtml": "<menuitem><p></p></menuitem>"
+ }
+ },
+ {
+ "data": "<!DOCTYPE html><menuitem><li>",
+ "errors": [],
+ "document": {
+ "props": {
+ "tags": {
+ "html": true,
+ "head": true,
+ "body": true,
+ "menuitem": true,
+ "li": true
+ },
+ "doctype": true
+ },
+ "tree": [
+ {
+ "doctype": "html"
+ },
+ {
+ "tag": "html",
+ "children": [
+ {
+ "tag": "head"
+ },
+ {
+ "tag": "body",
+ "children": [
+ {
+ "tag": "menuitem",
+ "children": [
+ {
+ "tag": "li"
+ }
+ ]
+ }
+ ]
+ }
+ ]
+ }
+ ],
+ "html": "<!DOCTYPE html><html><head></head><body><menuitem><li></li></menuitem></body></html>",
+ "noQuirksBodyHtml": "<menuitem><li></li></menuitem>"
+ }
+ }
+ ],
+ "namespace-sensitivity.dat": [
+ {
+ "data": "<body><table><tr><td><svg><td><foreignObject><span></td>Foo",
+ "errors": [],
+ "document": {
+ "props": {
+ "tags": {
+ "html": true,
+ "head": true,
+ "body": true,
+ "table": true,
+ "tbody": true,
+ "tr": true,
+ "td": true,
+ "svg svg": true,
+ "svg td": true,
+ "svg foreignObject": true,
+ "span": true
+ }
+ },
+ "tree": [
+ {
+ "tag": "html",
+ "children": [
+ {
+ "tag": "head"
+ },
+ {
+ "tag": "body",
+ "children": [
+ {
+ "text": "Foo"
+ },
+ {
+ "tag": "table",
+ "children": [
+ {
+ "tag": "tbody",
+ "children": [
+ {
+ "tag": "tr",
+ "children": [
+ {
+ "tag": "td",
+ "children": [
+ {
+ "tag": "svg",
+ "ns": "http://www.w3.org/2000/svg",
+ "children": [
+ {
+ "tag": "td",
+ "ns": "http://www.w3.org/2000/svg",
+ "children": [
+ {
+ "tag": "foreignObject",
+ "ns": "http://www.w3.org/2000/svg",
+ "children": [
+ {
+ "tag": "span"
+ }
+ ]
+ }
+ ]
+ }
+ ]
+ }
+ ]
+ }
+ ]
+ }
+ ]
+ }
+ ]
+ }
+ ]
+ }
+ ]
+ }
+ ],
+ "html": "<html><head></head><body>Foo<table><tbody><tr><td><svg><td><foreignObject><span></span></foreignObject></td></svg></td></tr></tbody></table></body></html>",
+ "noQuirksBodyHtml": "Foo<table><tbody><tr><td><svg><td><foreignObject><span></span></foreignObject></td></svg></td></tr></tbody></table>"
+ }
+ }
+ ],
+ "noscript01.dat": [
+ {
+ "data": "<head><noscript><!doctype html><!--foo--></noscript>",
+ "errors": [
+ "Line: 1 Col: 6 Unexpected start tag (head). Expected DOCTYPE.",
+ "Line: 1 Col: 31 Unexpected DOCTYPE. Ignored."
+ ],
+ "script": "off",
+ "document": {
+ "props": {
+ "tags": {
+ "html": true,
+ "head": true,
+ "noscript": true,
+ "body": true
+ },
+ "comment": true
+ },
+ "tree": [
+ {
+ "tag": "html",
+ "children": [
+ {
+ "tag": "head",
+ "children": [
+ {
+ "tag": "noscript",
+ "children": [
+ {
+ "comment": "foo"
+ }
+ ]
+ }
+ ]
+ },
+ {
+ "tag": "body"
+ }
+ ]
+ }
+ ],
+ "html": "<html><head><noscript><!--foo--></noscript></head><body></body></html>",
+ "noQuirksBodyHtml": "<noscript><!--foo--></noscript>"
+ }
+ },
+ {
+ "data": "<head><noscript><html class=\"foo\"><!--foo--></noscript>",
+ "errors": [
+ "Line: 1 Col: 6 Unexpected start tag (head). Expected DOCTYPE.",
+ "Line: 1 Col: 34 html needs to be the first start tag."
+ ],
+ "script": "off",
+ "document": {
+ "props": {
+ "tags": {
+ "html": true,
+ "head": true,
+ "noscript": true,
+ "body": true
+ },
+ "comment": true
+ },
+ "tree": [
+ {
+ "tag": "html",
+ "attrs": [
+ {
+ "name": "class",
+ "value": "foo"
+ }
+ ],
+ "children": [
+ {
+ "tag": "head",
+ "children": [
+ {
+ "tag": "noscript",
+ "children": [
+ {
+ "comment": "foo"
+ }
+ ]
+ }
+ ]
+ },
+ {
+ "tag": "body"
+ }
+ ]
+ }
+ ],
+ "html": "<html class=\"foo\"><head><noscript><!--foo--></noscript></head><body></body></html>",
+ "noQuirksBodyHtml": "<noscript><!--foo--></noscript>"
+ }
+ },
+ {
+ "data": "<head><noscript></noscript>",
+ "errors": [
+ "(1,6): expected-doctype-but-got-tag"
+ ],
+ "script": "off",
+ "document": {
+ "props": {
+ "tags": {
+ "html": true,
+ "head": true,
+ "noscript": true,
+ "body": true
+ }
+ },
+ "tree": [
+ {
+ "tag": "html",
+ "children": [
+ {
+ "tag": "head",
+ "children": [
+ {
+ "tag": "noscript"
+ }
+ ]
+ },
+ {
+ "tag": "body"
+ }
+ ]
+ }
+ ],
+ "html": "<html><head><noscript></noscript></head><body></body></html>",
+ "noQuirksBodyHtml": "<noscript></noscript>"
+ }
+ },
+ {
+ "data": "<head><noscript> </noscript>",
+ "errors": [
+ "Line: 1 Col: 6 Unexpected start tag (head). Expected DOCTYPE."
+ ],
+ "script": "off",
+ "document": {
+ "props": {
+ "tags": {
+ "html": true,
+ "head": true,
+ "noscript": true,
+ "body": true
+ },
+ "no_escape": true
+ },
+ "tree": [
+ {
+ "tag": "html",
+ "children": [
+ {
+ "tag": "head",
+ "children": [
+ {
+ "tag": "noscript",
+ "children": [
+ {
+ "text": " ",
+ "no_escape": true
+ }
+ ]
+ }
+ ]
+ },
+ {
+ "tag": "body"
+ }
+ ]
+ }
+ ],
+ "html": "<html><head><noscript> </noscript></head><body></body></html>",
+ "noQuirksBodyHtml": "<noscript> </noscript>"
+ }
+ },
+ {
+ "data": "<head><noscript><!--foo--></noscript>",
+ "errors": [
+ "(1,6): expected-doctype-but-got-tag"
+ ],
+ "script": "off",
+ "document": {
+ "props": {
+ "tags": {
+ "html": true,
+ "head": true,
+ "noscript": true,
+ "body": true
+ },
+ "comment": true
+ },
+ "tree": [
+ {
+ "tag": "html",
+ "children": [
+ {
+ "tag": "head",
+ "children": [
+ {
+ "tag": "noscript",
+ "children": [
+ {
+ "comment": "foo"
+ }
+ ]
+ }
+ ]
+ },
+ {
+ "tag": "body"
+ }
+ ]
+ }
+ ],
+ "html": "<html><head><noscript><!--foo--></noscript></head><body></body></html>",
+ "noQuirksBodyHtml": "<noscript><!--foo--></noscript>"
+ }
+ },
+ {
+ "data": "<head><noscript><basefont><!--foo--></noscript>",
+ "errors": [
+ "Line: 1 Col: 6 Unexpected start tag (head). Expected DOCTYPE."
+ ],
+ "script": "off",
+ "document": {
+ "props": {
+ "tags": {
+ "html": true,
+ "head": true,
+ "noscript": true,
+ "basefont": true,
+ "body": true
+ },
+ "comment": true
+ },
+ "tree": [
+ {
+ "tag": "html",
+ "children": [
+ {
+ "tag": "head",
+ "children": [
+ {
+ "tag": "noscript",
+ "children": [
+ {
+ "tag": "basefont"
+ },
+ {
+ "comment": "foo"
+ }
+ ]
+ }
+ ]
+ },
+ {
+ "tag": "body"
+ }
+ ]
+ }
+ ],
+ "html": "<html><head><noscript><basefont><!--foo--></noscript></head><body></body></html>",
+ "noQuirksBodyHtml": "<noscript><basefont><!--foo--></noscript>"
+ }
+ },
+ {
+ "data": "<head><noscript><bgsound><!--foo--></noscript>",
+ "errors": [
+ "Line: 1 Col: 6 Unexpected start tag (head). Expected DOCTYPE."
+ ],
+ "script": "off",
+ "document": {
+ "props": {
+ "tags": {
+ "html": true,
+ "head": true,
+ "noscript": true,
+ "bgsound": true,
+ "body": true
+ },
+ "comment": true
+ },
+ "tree": [
+ {
+ "tag": "html",
+ "children": [
+ {
+ "tag": "head",
+ "children": [
+ {
+ "tag": "noscript",
+ "children": [
+ {
+ "tag": "bgsound"
+ },
+ {
+ "comment": "foo"
+ }
+ ]
+ }
+ ]
+ },
+ {
+ "tag": "body"
+ }
+ ]
+ }
+ ],
+ "html": "<html><head><noscript><bgsound><!--foo--></noscript></head><body></body></html>",
+ "noQuirksBodyHtml": "<noscript><bgsound><!--foo--></noscript>"
+ }
+ },
+ {
+ "data": "<head><noscript><link><!--foo--></noscript>",
+ "errors": [
+ "Line: 1 Col: 6 Unexpected start tag (head). Expected DOCTYPE."
+ ],
+ "script": "off",