mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 20:07:35 +00:00
LibWeb: Implement the <style>
SVG element
The `<style>` element is allowed to be in the SVG namespace, so we now support this element. It has the same behaviour as the HTML namespace `<style>` element as described in the spec. "The semantics and processing of a ‘style’ and its attributes must be the same as is defined for the HTML ‘style’ element."
This commit is contained in:
parent
7f7ebc4b8b
commit
e2a935b1dc
7 changed files with 118 additions and 0 deletions
|
@ -97,6 +97,7 @@
|
|||
#include <LibWeb/SVG/SVGRectElement.h>
|
||||
#include <LibWeb/SVG/SVGSVGElement.h>
|
||||
#include <LibWeb/SVG/SVGStopElement.h>
|
||||
#include <LibWeb/SVG/SVGStyleElement.h>
|
||||
#include <LibWeb/SVG/SVGSymbolElement.h>
|
||||
#include <LibWeb/SVG/SVGTextContentElement.h>
|
||||
#include <LibWeb/SVG/SVGTitleElement.h>
|
||||
|
@ -456,6 +457,8 @@ static WebIDL::ExceptionOr<JS::GCPtr<SVG::SVGElement>> create_svg_element(JS::Re
|
|||
return MUST_OR_THROW_OOM(realm.heap().allocate<SVG::SVGGElement>(realm, document, move(qualified_name)));
|
||||
if (local_name == SVG::TagNames::stop)
|
||||
return MUST_OR_THROW_OOM(realm.heap().allocate<SVG::SVGStopElement>(realm, document, move(qualified_name)));
|
||||
if (local_name == SVG::TagNames::style)
|
||||
return MUST_OR_THROW_OOM(realm.heap().allocate<SVG::SVGStyleElement>(realm, document, move(qualified_name)));
|
||||
if (local_name == SVG::TagNames::symbol)
|
||||
return MUST_OR_THROW_OOM(realm.heap().allocate<SVG::SVGSymbolElement>(realm, document, move(qualified_name)));
|
||||
if (local_name == SVG::TagNames::text)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue