mirror of
https://github.com/RGBCube/serenity
synced 2025-05-20 13:25:08 +00:00
LibWeb: Generate MathML Elements
We will now generate MathML elements when parsing HTML.
This commit is contained in:
parent
52d6df5ee5
commit
442602bec8
8 changed files with 123 additions and 1 deletions
|
@ -1430,6 +1430,7 @@ HTMLParser::AdoptionAgencyAlgorithmOutcome HTMLParser::run_the_adoption_agency_a
|
|||
}
|
||||
}
|
||||
|
||||
// https://html.spec.whatwg.org/multipage/parsing.html#special
|
||||
bool HTMLParser::is_special_tag(DeprecatedFlyString const& tag_name, DeprecatedFlyString const& namespace_)
|
||||
{
|
||||
if (namespace_ == Namespace::HTML) {
|
||||
|
@ -1522,7 +1523,12 @@ bool HTMLParser::is_special_tag(DeprecatedFlyString const& tag_name, DeprecatedF
|
|||
SVG::TagNames::foreignObject,
|
||||
SVG::TagNames::title);
|
||||
} else if (namespace_ == Namespace::MathML) {
|
||||
TODO();
|
||||
return tag_name.is_one_of(
|
||||
MathML::TagNames::mi,
|
||||
MathML::TagNames::mo,
|
||||
MathML::TagNames::mn,
|
||||
MathML::TagNames::mtext,
|
||||
MathML::TagNames::annotation_xml);
|
||||
}
|
||||
|
||||
return false;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue