LibWeb: Implement <desc> SVG element

This commit is contained in:
Jamie Mansfield 2024-04-15 18:43:01 +01:00 committed by Andreas Kling
commit 2d90317c20
Notes: sideshowbarker 2024-07-16 23:51:07 +09:00
9 changed files with 71 additions and 0 deletions

View file

@ -87,6 +87,7 @@
#include <LibWeb/SVG/SVGCircleElement.h>
#include <LibWeb/SVG/SVGClipPathElement.h>
#include <LibWeb/SVG/SVGDefsElement.h>
#include <LibWeb/SVG/SVGDescElement.h>
#include <LibWeb/SVG/SVGEllipseElement.h>
#include <LibWeb/SVG/SVGForeignObjectElement.h>
#include <LibWeb/SVG/SVGGElement.h>
@ -439,6 +440,8 @@ static JS::GCPtr<SVG::SVGElement> create_svg_element(JS::Realm& realm, Document&
return realm.heap().allocate<SVG::SVGCircleElement>(realm, document, move(qualified_name));
if (local_name.equals_ignoring_ascii_case(SVG::TagNames::defs))
return realm.heap().allocate<SVG::SVGDefsElement>(realm, document, move(qualified_name));
if (local_name == SVG::TagNames::desc)
return realm.heap().allocate<SVG::SVGDescElement>(realm, document, move(qualified_name));
if (local_name == SVG::TagNames::ellipse)
return realm.heap().allocate<SVG::SVGEllipseElement>(realm, document, move(qualified_name));
if (local_name.equals_ignoring_ascii_case(SVG::TagNames::foreignObject))