Truly independent web browser
LibWeb: Add SVGMarkerElement, SVGAngle and SVGAnimatedAngle
Andreas Kling8de47ea3b311
diff --git a/Libraries/LibWeb/CMakeLists.txt b/Libraries/LibWeb/CMakeLists.txtindex f8cb1875686..4110da8ed46 100644--- a/Libraries/LibWeb/CMakeLists.txt+++ b/Libraries/LibWeb/CMakeLists.txt@@ -855,6 +855,8 @@ set(SOURCESSVG/SMILAnimation.cppSVG/SMILTimeContainer.cppSVG/SVGAElement.cpp+ SVG/SVGAngle.cpp+ SVG/SVGAnimatedAngle.cppSVG/SVGAnimatedBoolean.cppSVG/SVGAnimatedEnumeration.cppSVG/SVGAnimatedInteger.cpp@@ -914,6 +916,7 @@ set(SOURCESSVG/SVGLinearGradientElement.cppSVG/SVGLineElement.cppSVG/SVGList.cpp+ SVG/SVGMarkerElement.cppSVG/SVGMaskElement.cppSVG/SVGMetadataElement.cppSVG/SVGMPathElement.cppdiff --git a/Libraries/LibWeb/DOM/ElementFactory.cpp b/Libraries/LibWeb/DOM/ElementFactory.cppindex d3540b67168..f9baf72ff42 100644--- a/Libraries/LibWeb/DOM/ElementFactory.cpp+++ b/Libraries/LibWeb/DOM/ElementFactory.cpp@@ -132,6 +132,7 @@#include <LibWeb/SVG/SVGLineElement.h>#include <LibWeb/SVG/SVGLinearGradientElement.h>#include <LibWeb/SVG/SVGMPathElement.h>+#include <LibWeb/SVG/SVGMarkerElement.h>#include <LibWeb/SVG/SVGMaskElement.h>#include <LibWeb/SVG/SVGMetadataElement.h>#include <LibWeb/SVG/SVGPathElement.h>@@ -589,6 +590,8 @@ static GC::Ref<SVG::SVGElement> create_svg_element(Document& document, Qualifiedreturn create_element_on_heap<SVG::SVGLineElement>(document, move(qualified_name));if (local_name == SVG::TagNames::linearGradient)return create_element_on_heap<SVG::SVGLinearGradientElement>(document, move(qualified_name));+ if (local_name == SVG::TagNames::marker)+ return create_element_on_heap<SVG::SVGMarkerElement>(document, move(qualified_name));if (local_name == SVG::TagNames::mask)return create_element_on_heap<SVG::SVGMaskElement>(document, move(qualified_name));if (local_name == SVG::TagNames::metadata)diff --git a/Libraries/LibWeb/SVG/AttributeNames.h b/Libraries/LibWeb/SVG/AttributeNames.hindex 4c2c82a05e4..f26181f2e0a 100644--- a/Libraries/LibWeb/SVG/AttributeNames.h+++ b/Libraries/LibWeb/SVG/AttributeNames.h@@ -73,6 +73,7 @@ namespace Web::SVG::AttributeNames {__ENUMERATE_SVG_ATTRIBUTE(opacity, "opacity") \__ENUMERATE_SVG_ATTRIBUTE(operator_, "operator") \__ENUMERATE_SVG_ATTRIBUTE(order, "order") \+ __ENUMERATE_SVG_ATTRIBUTE(orient, "orient") \__ENUMERATE_SVG_ATTRIBUTE(path, "path") \__ENUMERATE_SVG_ATTRIBUTE(pathLength, "pathLength") \__ENUMERATE_SVG_ATTRIBUTE(patternContentUnits, "patternContentUnits") \diff --git a/Libraries/LibWeb/SVG/SVGAngle.cpp b/Libraries/LibWeb/SVG/SVGAngle.cppnew file mode 100644index 00000000000..80081c8de0f--- /dev/null+++ b/Libraries/LibWeb/SVG/SVGAngle.cpp@@ -0,0 +1,278 @@+/*+ * Copyright (c) 2026-present, the Ladybird developers.+ *+ * SPDX-License-Identifier: BSD-2-Clause+ */++#include <AK/Utf16StringBuilder.h>+#include <LibGC/Heap.h>+#include <LibWeb/CSS/Angle.h>+#include <LibWeb/CSS/Parser/Parser.h>+#include <LibWeb/CSS/Serialize.h>+#include <LibWeb/CSS/StyleValues/AngleStyleValue.h>+#include <LibWeb/CSS/StyleValues/NumberStyleValue.h>+#include <LibWeb/SVG/SVGAngle.h>+#include <LibWeb/SVG/SVGElement.h>++namespace Web::SVG {++GC_DEFINE_ALLOCATOR(SVGAngle);++GC::Ref<SVGAngle> SVGAngle::create_detached(Value value, ReadOnly read_only)+{+ return GC::Heap::the().allocate<SVGAngle>(DetachedSource { value }, read_only);+}++GC::Ref<SVGAngle> SVGAngle::create_reflected_attribute(GC::Ref<SVGElement> element, Utf16FlyString name, ReadOnly read_only)+{+ return GC::Heap::the().allocate<SVGAngle>(ReflectedAttributeSource { element, move(name) }, read_only);+}++SVGAngle::SVGAngle(Source source, ReadOnly read_only)+ : m_source(move(source))+ , m_read_only(read_only)+{+}++SVGAngle::~SVGAngle() = default;++void SVGAngle::visit_edges(Cell::Visitor& visitor)+{+ Base::visit_edges(visitor);+ if (auto* source = m_source.get_pointer<ReflectedAttributeSource>())+ visitor.visit(source->element);+}++// Parses a value using the CSS syntax [ <number> | <angle> ].+Optional<SVGAngle::Value> SVGAngle::parse(Utf16View input)+{+ CSS::Parser::ParsingParams parsing_params { CSS::Parser::ParsingMode::SVGPresentationAttribute };+ if (auto number = parse_css_type(parsing_params, input, CSS::ValueType::Number); number && number->is_number())+ return Value { static_cast<float>(number->as_number().number()), {} };+ // FIXME: Support math functions, which do not parse to a literal number or angle.+ if (auto angle = parse_css_type(parsing_params, input, CSS::ValueType::Angle); angle && angle->is_angle()) {+ auto value = angle->as_angle().angle();+ return Value { static_cast<float>(value.raw_value()), value.unit() };+ }+ return {};+}++// https://svgwg.org/svg2-draft/types.html#__svg__SVGAngle__valueAsString+Utf16String SVGAngle::serialize(Value value)+{+ // 2. Let string be an empty string.+ Utf16StringBuilder builder;++ // 3. Let factor be value's numeric factor, if it is an <angle>, or value itself it is a <number>.+ // 4. Append to string an implementation specific string that, if parsed as a <number> using CSS syntax, would+ // return the number value closest to factor, given the implementation's supported real number precision.+ CSS::serialize_a_number(builder, value.factor);++ // 5. If value is an <angle>, then append to string the canonical spelling of value's unit.+ if (value.unit.has_value())+ builder.append(CSS::to_string(*value.unit));++ // 6. Return string.+ return builder.to_string();+}++SVGAngle::Value SVGAngle::internal_value() const+{+ return m_source.visit(+ [](ReflectedAttributeSource const& source) {+ // NB: The value of a reflected attribute that is not present or invalid is its initial value. The only+ // attribute reflected by an SVGAngle is orient, whose initial value is 0.+ return parse(source.element->get_attribute_value(source.name)).value_or({});+ },+ [](DetachedSource const& source) { return source.value; });+}++void SVGAngle::set_internal_value(Value value)+{+ m_source.visit(+ [&](ReflectedAttributeSource const& source) {+ // https://svgwg.org/svg2-draft/types.html#TermReserialize+ source.element->set_attribute_value(source.name, serialize(value));+ },+ [&](DetachedSource& source) { source.value = value; });+}++WebIDL::ExceptionOr<void> SVGAngle::ensure_not_read_only() const+{+ if (m_read_only == ReadOnly::Yes)+ return WebIDL::NoModificationAllowedError::create("Cannot modify a read-only SVGAngle"_utf16);+ return {};+}++static Optional<CSS::AngleUnit> angle_unit_for_unit_type(u16 unit_type)+{+ switch (unit_type) {+ case SVGAngle::SVG_ANGLETYPE_DEG:+ return CSS::AngleUnit::Deg;+ case SVGAngle::SVG_ANGLETYPE_RAD:+ return CSS::AngleUnit::Rad;+ case SVGAngle::SVG_ANGLETYPE_GRAD:+ return CSS::AngleUnit::Grad;+ default:+ return {};+ }+}++// https://svgwg.org/svg2-draft/types.html#__svg__SVGAngle__unitType+u16 SVGAngle::unit_type() const+{+ // 1. If the SVGAngle's value is a unitless <number> or a <length> with a deg, rad or grad unit, then return the+ // corresponding constant value from the angle unit type table above.+ auto value = internal_value();+ if (!value.unit.has_value())+ return SVG_ANGLETYPE_UNSPECIFIED;+ switch (*value.unit) {+ case CSS::AngleUnit::Deg:+ return SVG_ANGLETYPE_DEG;+ case CSS::AngleUnit::Rad:+ return SVG_ANGLETYPE_RAD;+ case CSS::AngleUnit::Grad:+ return SVG_ANGLETYPE_GRAD;+ default:+ // 2. Otherwise, return SVG_ANGLETYPE_UNKNOWN.+ return SVG_ANGLETYPE_UNKNOWN;+ }+}++// https://svgwg.org/svg2-draft/types.html#__svg__SVGAngle__value+float SVGAngle::value() const+{+ // 1. Let value be the SVGAngle's value.+ auto value = internal_value();++ // 2. If value is a <number>, return that number.+ if (!value.unit.has_value())+ return value.factor;++ // 3. Return the result of converting value to an angle in degrees.+ return static_cast<float>(CSS::Angle { value.factor, *value.unit }.to_degrees());+}++// https://svgwg.org/svg2-draft/types.html#__svg__SVGAngle__value+WebIDL::ExceptionOr<void> SVGAngle::set_value(float value)+{+ // 1. If the SVGAngle object is read only, then throw a NoModificationAllowedError.+ TRY(ensure_not_read_only());++ // 2. Let value be the value being assigned to value.+ // 3. Set the SVGAngle's value to a <number> whose value is value.+ // 4. If the SVGAngle reflects the base value of a reflected attribute, then reserialize the reflected attribute.+ set_internal_value({ value, {} });+ return {};+}++// https://svgwg.org/svg2-draft/types.html#__svg__SVGAngle__valueInSpecifiedUnits+float SVGAngle::value_in_specified_units() const+{+ // 1. Let value be the SVGAngle's value.+ // 2. If value is a <number>, return that number.+ // 3. Otherwise, value is an <angle> value. Return the numeric factor before its unit.+ return internal_value().factor;+}++// https://svgwg.org/svg2-draft/types.html#__svg__SVGAngle__valueInSpecifiedUnits+WebIDL::ExceptionOr<void> SVGAngle::set_value_in_specified_units(float value)+{+ // 1. If the SVGAngle object is read only, then throw a NoModificationAllowedError.+ TRY(ensure_not_read_only());++ // 2. Let value be the value being assigned to valueInSpecifiedUnits.+ // 3. If the SVGAngle's value is a <number>, then update its value to value.+ // 4. Otherwise, if the SVGAngle's value is an <angle>, then update its numeric factor to value.+ auto new_value = internal_value();+ new_value.factor = value;++ // 5. If the SVGAngle reflects the base value of a reflected attribute or reflects an element of the base value of+ // a reflected attribute, then reserialize the reflected attribute.+ set_internal_value(new_value);+ return {};+}++// https://svgwg.org/svg2-draft/types.html#__svg__SVGAngle__valueAsString+Utf16String SVGAngle::value_as_string() const+{+ // 1. Let value be the SVGAngle's value.+ return serialize(internal_value());+}++// https://svgwg.org/svg2-draft/types.html#__svg__SVGAngle__valueAsString+WebIDL::ExceptionOr<void> SVGAngle::set_value_as_string(Utf16String const& value)+{+ // 1. If the SVGAngle object is read only, then throw a NoModificationAllowedError.+ TRY(ensure_not_read_only());++ // 2. Let value be the value being assigned to valueAsString.+ // 3. Parse value using the CSS syntax [ <number> | <angle> ].+ auto parsed_value = parse(value);++ // 4. If parsing failed, then throw a SyntaxError.+ if (!parsed_value.has_value())+ return WebIDL::SyntaxError::create("Failed to parse value as a <number> or <angle>"_utf16);++ // 5. Otherwise, parsing succeeded. Set SVGAngle's value to the parsed value.+ // 6. If the SVGAngle reflects the base value of a reflected attribute or reflects an element of the base value of+ // a reflected attribute, then reserialize the reflected attribute.+ set_internal_value(*parsed_value);+ return {};+}++// https://svgwg.org/svg2-draft/types.html#__svg__SVGAngle__newValueSpecifiedUnits+WebIDL::ExceptionOr<void> SVGAngle::new_value_specified_units(u16 unit_type, float value_in_specified_units)+{+ // 1. If the SVGAngle object is read only, then throw a NoModificationAllowedError.+ TRY(ensure_not_read_only());++ // 2. If unitType is SVG_ANGLETYPE_UNKNOWN or is a value that does not appear in the angle unit type table above,+ // then throw a NotSupportedError.+ if (unit_type == SVG_ANGLETYPE_UNKNOWN || unit_type > SVG_ANGLETYPE_GRAD)+ return WebIDL::NotSupportedError::create("Unsupported angle unit type"_utf16);++ // 3. Set SVGAngle's value depending on the value of unitType:+ // SVG_ANGLETYPE_UNSPECIFIED: a <number> whose value is valueInSpecifiedUnits+ // anything else: an <angle> whose numeric factor is valueInSpecifiedUnits and whose unit is as indicated by the+ // angle unit type table above+ // 4. If the SVGAngle reflects the base value of a reflected attribute or reflects an element of the base value of+ // a reflected attribute, then reserialize the reflected attribute.+ set_internal_value({ value_in_specified_units, angle_unit_for_unit_type(unit_type) });+ return {};+}++// https://svgwg.org/svg2-draft/types.html#__svg__SVGAngle__convertToSpecifiedUnits+WebIDL::ExceptionOr<void> SVGAngle::convert_to_specified_units(u16 unit_type)+{+ // 1. If the SVGAngle object is read only, then throw a NoModificationAllowedError.+ TRY(ensure_not_read_only());++ // 2. If unitType is SVG_ANGLETYPE_UNKNOWN or is a value that does not appear in the angle unit type table above,+ // then throw a NotSupportedError.+ if (unit_type == SVG_ANGLETYPE_UNKNOWN || unit_type > SVG_ANGLETYPE_GRAD)+ return WebIDL::NotSupportedError::create("Unsupported angle unit type"_utf16);++ // 3. Let degrees be the value that would be returned from the value member.+ auto degrees = value();++ // 4. If unitType is SVG_ANGLETYPE_UNSPECIFIED, then:+ if (unit_type == SVG_ANGLETYPE_UNSPECIFIED) {+ // 1. Set the SVGAngle's value to a <number> whose value is degrees.+ set_internal_value({ degrees, {} });+ }+ // 5. Otherwise:+ else {+ // 1. Set the SVGAngle's value to the result of converting degrees to an <angle> with the unit found by looking+ // up unitType in the angle unit type table above.+ auto unit = *angle_unit_for_unit_type(unit_type);+ set_internal_value({ static_cast<float>(degrees * CSS::ratio_between_units(CSS::AngleUnit::Deg, unit)), unit });+ }++ // 6. If the SVGAngle reflects the base value of a reflected attribute or reflects an element of the base value of+ // a reflected attribute, then reserialize the reflected attribute.+ // NB: This happens as part of setting the value above.+ return {};+}++}diff --git a/Libraries/LibWeb/SVG/SVGAngle.h b/Libraries/LibWeb/SVG/SVGAngle.hnew file mode 100644index 00000000000..91feca20796--- /dev/null+++ b/Libraries/LibWeb/SVG/SVGAngle.h@@ -0,0 +1,94 @@+/*+ * Copyright (c) 2026-present, the Ladybird developers.+ *+ * SPDX-License-Identifier: BSD-2-Clause+ */++#pragma once++#include <AK/Utf16FlyString.h>+#include <AK/Variant.h>+#include <LibWeb/Bindings/Wrappable.h>+#include <LibWeb/CSS/Units.h>+#include <LibWeb/Forward.h>+#include <LibWeb/WebIDL/ExceptionOr.h>++namespace Web::SVG {++// https://svgwg.org/svg2-draft/types.html#InterfaceSVGAngle+class SVGAngle final : public Bindings::GCAllocatedWrappable {+ WEB_WRAPPABLE(SVGAngle, Bindings::GCAllocatedWrappable);+ GC_DECLARE_ALLOCATOR(SVGAngle);++public:+ static constexpr u16 SVG_ANGLETYPE_UNKNOWN = 0;+ static constexpr u16 SVG_ANGLETYPE_UNSPECIFIED = 1;+ static constexpr u16 SVG_ANGLETYPE_DEG = 2;+ static constexpr u16 SVG_ANGLETYPE_RAD = 3;+ static constexpr u16 SVG_ANGLETYPE_GRAD = 4;++ enum class ReadOnly : u8 {+ Yes,+ No,+ };++ // An <angle> or <number> value. A number has no unit.+ struct Value {+ float factor { 0 };+ Optional<CSS::AngleUnit> unit;+ };++ static Optional<Value> parse(Utf16View);+ static Utf16String serialize(Value);++ [[nodiscard]] static GC::Ref<SVGAngle> create_detached(Value, ReadOnly);+ [[nodiscard]] static GC::Ref<SVGAngle> create_reflected_attribute(GC::Ref<SVGElement>, Utf16FlyString name, ReadOnly);++ virtual ~SVGAngle() override;++ u16 unit_type() const;++ float value() const;+ WebIDL::ExceptionOr<void> set_value(float);++ float value_in_specified_units() const;+ WebIDL::ExceptionOr<void> set_value_in_specified_units(float);++ Utf16String value_as_string() const;+ WebIDL::ExceptionOr<void> set_value_as_string(Utf16String const&);++ WebIDL::ExceptionOr<void> new_value_specified_units(u16 unit_type, float value_in_specified_units);+ WebIDL::ExceptionOr<void> convert_to_specified_units(u16 unit_type);++ Value internal_value() const;++private:+ // Every SVGAngle object operates in one of two modes. It can:+ // 1. reflect the base value of a reflected animatable attribute (being exposed through the baseVal member of an+ // SVGAnimatedAngle),+ struct ReflectedAttributeSource {+ GC::Ref<SVGElement> element;+ Utf16FlyString name;+ };++ // 2. be detached, which is the case for SVGAngle objects created with createSVGAngle.+ struct DetachedSource {+ Value value;+ };++ using Source = Variant<ReflectedAttributeSource, DetachedSource>;++ SVGAngle(Source, ReadOnly);++ virtual void visit_edges(Cell::Visitor&) override;++ WebIDL::ExceptionOr<void> ensure_not_read_only() const;+ void set_internal_value(Value);++ Source m_source;++ // https://svgwg.org/svg2-draft/types.html#ReadOnlyAngle+ ReadOnly m_read_only;+};++}diff --git a/Libraries/LibWeb/SVG/SVGAngle.idl b/Libraries/LibWeb/SVG/SVGAngle.idlnew file mode 100644index 00000000000..401e521296b--- /dev/null+++ b/Libraries/LibWeb/SVG/SVGAngle.idl@@ -0,0 +1,19 @@+// https://svgwg.org/svg2-draft/types.html#InterfaceSVGAngle+[Exposed=Window]+interface SVGAngle {++ // Angle Unit Types+ const unsigned short SVG_ANGLETYPE_UNKNOWN = 0;+ const unsigned short SVG_ANGLETYPE_UNSPECIFIED = 1;+ const unsigned short SVG_ANGLETYPE_DEG = 2;+ const unsigned short SVG_ANGLETYPE_RAD = 3;+ const unsigned short SVG_ANGLETYPE_GRAD = 4;++ readonly attribute unsigned short unitType;+ attribute float value;+ attribute float valueInSpecifiedUnits;+ attribute DOMString valueAsString;++ undefined newValueSpecifiedUnits(unsigned short unitType, float valueInSpecifiedUnits);+ undefined convertToSpecifiedUnits(unsigned short unitType);+};diff --git a/Libraries/LibWeb/SVG/SVGAnimatedAngle.cpp b/Libraries/LibWeb/SVG/SVGAnimatedAngle.cppnew file mode 100644index 00000000000..7b6fac1d657--- /dev/null+++ b/Libraries/LibWeb/SVG/SVGAnimatedAngle.cpp@@ -0,0 +1,34 @@+/*+ * Copyright (c) 2026-present, the Ladybird developers.+ *+ * SPDX-License-Identifier: BSD-2-Clause+ */++#include <LibGC/Heap.h>+#include <LibWeb/SVG/SVGAnimatedAngle.h>++namespace Web::SVG {++GC_DEFINE_ALLOCATOR(SVGAnimatedAngle);++GC::Ref<SVGAnimatedAngle> SVGAnimatedAngle::create(GC::Ref<SVGAngle> base_val, GC::Ref<SVGAngle> anim_val)+{+ return GC::Heap::the().allocate<SVGAnimatedAngle>(base_val, anim_val);+}++SVGAnimatedAngle::SVGAnimatedAngle(GC::Ref<SVGAngle> base_val, GC::Ref<SVGAngle> anim_val)+ : m_base_val(base_val)+ , m_anim_val(anim_val)+{+}++SVGAnimatedAngle::~SVGAnimatedAngle() = default;++void SVGAnimatedAngle::visit_edges(Cell::Visitor& visitor)+{+ Base::visit_edges(visitor);+ visitor.visit(m_base_val);+ visitor.visit(m_anim_val);+}++}diff --git a/Libraries/LibWeb/SVG/SVGAnimatedAngle.h b/Libraries/LibWeb/SVG/SVGAnimatedAngle.hnew file mode 100644index 00000000000..ed69dbe88c6--- /dev/null+++ b/Libraries/LibWeb/SVG/SVGAnimatedAngle.h@@ -0,0 +1,35 @@+/*+ * Copyright (c) 2026-present, the Ladybird developers.+ *+ * SPDX-License-Identifier: BSD-2-Clause+ */++#pragma once++#include <LibWeb/Bindings/Wrappable.h>+#include <LibWeb/SVG/SVGAngle.h>++namespace Web::SVG {++// https://svgwg.org/svg2-draft/types.html#InterfaceSVGAnimatedAngle+class SVGAnimatedAngle final : public Bindings::GCAllocatedWrappable {+ WEB_WRAPPABLE(SVGAnimatedAngle, Bindings::GCAllocatedWrappable);+ GC_DECLARE_ALLOCATOR(SVGAnimatedAngle);++public:+ [[nodiscard]] static GC::Ref<SVGAnimatedAngle> create(GC::Ref<SVGAngle> base_val, GC::Ref<SVGAngle> anim_val);+ virtual ~SVGAnimatedAngle() override;++ GC::Ref<SVGAngle> base_val() const { return m_base_val; }+ GC::Ref<SVGAngle> anim_val() const { return m_anim_val; }++private:+ SVGAnimatedAngle(GC::Ref<SVGAngle> base_val, GC::Ref<SVGAngle> anim_val);++ virtual void visit_edges(Cell::Visitor&) override;++ GC::Ref<SVGAngle> m_base_val;+ GC::Ref<SVGAngle> m_anim_val;+};++}diff --git a/Libraries/LibWeb/SVG/SVGAnimatedAngle.idl b/Libraries/LibWeb/SVG/SVGAnimatedAngle.idlnew file mode 100644index 00000000000..2ba8ec622b6--- /dev/null+++ b/Libraries/LibWeb/SVG/SVGAnimatedAngle.idl@@ -0,0 +1,6 @@+// https://svgwg.org/svg2-draft/types.html#InterfaceSVGAnimatedAngle+[Exposed=Window]+interface SVGAnimatedAngle {+ [SameObject] readonly attribute SVGAngle baseVal;+ [SameObject] readonly attribute SVGAngle animVal;+};diff --git a/Libraries/LibWeb/SVG/SVGAnimatedEnumeration.cpp b/Libraries/LibWeb/SVG/SVGAnimatedEnumeration.cppindex e60b2a416d3..d9fe6755f4d 100644--- a/Libraries/LibWeb/SVG/SVGAnimatedEnumeration.cpp+++ b/Libraries/LibWeb/SVG/SVGAnimatedEnumeration.cpp@@ -5,24 +5,27 @@*/#include <LibGC/Heap.h>+#include <LibWeb/SVG/SVGAngle.h>#include <LibWeb/SVG/SVGAnimatedEnumeration.h>#include <LibWeb/SVG/SVGElement.h>+#include <LibWeb/SVG/SVGMarkerElement.h>#include <LibWeb/WebIDL/ExceptionOr.h>namespace Web::SVG {GC_DEFINE_ALLOCATOR(SVGAnimatedEnumeration);-GC::Ref<SVGAnimatedEnumeration> SVGAnimatedEnumeration::create(GC::Ref<SVGElement> element, Utf16FlyString reflected_attribute, ReadonlySpan<Keyword> keywords, u16 initial_value)+GC::Ref<SVGAnimatedEnumeration> SVGAnimatedEnumeration::create(GC::Ref<SVGElement> element, Utf16FlyString reflected_attribute, ReadonlySpan<Keyword> keywords, u16 initial_value, ReflectsOrientType reflects_orient_type){- return GC::Heap::the().allocate<SVGAnimatedEnumeration>(element, move(reflected_attribute), keywords, initial_value);+ return GC::Heap::the().allocate<SVGAnimatedEnumeration>(element, move(reflected_attribute), keywords, initial_value, reflects_orient_type);}-SVGAnimatedEnumeration::SVGAnimatedEnumeration(GC::Ref<SVGElement> element, Utf16FlyString reflected_attribute, ReadonlySpan<Keyword> keywords, u16 initial_value)+SVGAnimatedEnumeration::SVGAnimatedEnumeration(GC::Ref<SVGElement> element, Utf16FlyString reflected_attribute, ReadonlySpan<Keyword> keywords, u16 initial_value, ReflectsOrientType reflects_orient_type): m_element(element), m_reflected_attribute(move(reflected_attribute)), m_keywords(keywords), m_initial_value(initial_value)+ , m_reflects_orient_type(reflects_orient_type){}@@ -51,11 +54,16 @@ WebIDL::ExceptionOr<void> SVGAnimatedEnumeration::set_base_val(u16 base_val)}return {};}();- if (!keyword.has_value())+ auto is_orient_angle = m_reflects_orient_type == ReflectsOrientType::Yes && value == SVGMarkerElement::SVG_MARKER_ORIENT_ANGLE;+ if (!keyword.has_value() && !is_orient_angle)return WebIDL::SimpleException { WebIDL::SimpleExceptionType::TypeError, "Invalid value for baseVal"_utf16 };- // FIXME: 3. Otherwise, if the reflecting IDL attribute is orientType and value is SVG_MARKER_ORIENT_ANGLE, then set the+ // 3. Otherwise, if the reflecting IDL attribute is orientType and value is SVG_MARKER_ORIENT_ANGLE, then set the// reflected attribute to the string "0".+ if (is_orient_angle) {+ m_element->set_attribute_value(m_reflected_attribute, "0"_utf16);+ return {};+ }// 4. Otherwise, value is the numeric type value for a specific, single keyword value for the reflected attribute.// Set the reflected attribute to that value.@@ -76,6 +84,9 @@ u16 SVGAnimatedEnumeration::base_or_anim_value() constif (value.utf16_view() == mapping.keyword)return mapping.value;}+ // NB: For orientType, an <angle> or <number> value maps to SVG_MARKER_ORIENT_ANGLE.+ if (m_reflects_orient_type == ReflectsOrientType::Yes && SVGAngle::parse(value).has_value())+ return SVGMarkerElement::SVG_MARKER_ORIENT_ANGLE;return m_initial_value;}diff --git a/Libraries/LibWeb/SVG/SVGAnimatedEnumeration.h b/Libraries/LibWeb/SVG/SVGAnimatedEnumeration.hindex 240b6828fad..b5f4adebabd 100644--- a/Libraries/LibWeb/SVG/SVGAnimatedEnumeration.h+++ b/Libraries/LibWeb/SVG/SVGAnimatedEnumeration.h@@ -27,7 +27,14 @@ public:u16 value;};- [[nodiscard]] static GC::Ref<SVGAnimatedEnumeration> create(GC::Ref<SVGElement>, Utf16FlyString reflected_attribute, ReadonlySpan<Keyword> keywords, u16 initial_value);+ // Whether the reflecting IDL attribute is SVGMarkerElement's orientType, whose reflected attribute can also take an+ // angle value.+ enum class ReflectsOrientType : u8 {+ No,+ Yes,+ };++ [[nodiscard]] static GC::Ref<SVGAnimatedEnumeration> create(GC::Ref<SVGElement>, Utf16FlyString reflected_attribute, ReadonlySpan<Keyword> keywords, u16 initial_value, ReflectsOrientType = ReflectsOrientType::No);virtual ~SVGAnimatedEnumeration() override;u16 base_val() const { return base_or_anim_value(); }@@ -36,7 +43,7 @@ public:u16 anim_val() const { return base_or_anim_value(); }private:- SVGAnimatedEnumeration(GC::Ref<SVGElement>, Utf16FlyString reflected_attribute, ReadonlySpan<Keyword> keywords, u16 initial_value);+ SVGAnimatedEnumeration(GC::Ref<SVGElement>, Utf16FlyString reflected_attribute, ReadonlySpan<Keyword> keywords, u16 initial_value, ReflectsOrientType);virtual void visit_edges(Cell::Visitor&) override;@@ -46,6 +53,7 @@ private:Utf16FlyString m_reflected_attribute;ReadonlySpan<Keyword> m_keywords;u16 m_initial_value { 0 };+ ReflectsOrientType m_reflects_orient_type { ReflectsOrientType::No };};}diff --git a/Libraries/LibWeb/SVG/SVGMarkerElement.cpp b/Libraries/LibWeb/SVG/SVGMarkerElement.cppnew file mode 100644index 00000000000..90a5856065f--- /dev/null+++ b/Libraries/LibWeb/SVG/SVGMarkerElement.cpp@@ -0,0 +1,89 @@+/*+ * Copyright (c) 2026-present, the Ladybird developers.+ *+ * SPDX-License-Identifier: BSD-2-Clause+ */++#include <LibWeb/SVG/AttributeNames.h>+#include <LibWeb/SVG/SVGMarkerElement.h>++namespace Web::SVG {++GC_DEFINE_ALLOCATOR(SVGMarkerElement);++SVGMarkerElement::SVGMarkerElement(DOM::Document& document, DOM::QualifiedName qualified_name)+ : SVGElement(document, qualified_name)+{+}++void SVGMarkerElement::initialize_element()+{+ SVGFitToViewBox::initialize_fit_to_view_box();+}++void SVGMarkerElement::visit_edges(Cell::Visitor& visitor)+{+ Base::visit_edges(visitor);+ SVGFitToViewBox::visit_edges(visitor);+ visitor.visit(m_orient_type);+ visitor.visit(m_orient_angle);+}++void SVGMarkerElement::attribute_changed(Utf16FlyString const& name, Optional<Utf16String> const& old_value, Optional<Utf16String> const& value, Optional<Utf16FlyString> const& namespace_)+{+ Base::attribute_changed(name, old_value, value, namespace_);+ SVGFitToViewBox::attribute_changed(*this, name, value);+}++// https://svgwg.org/svg2-draft/painting.html#__svg__SVGMarkerElement__markerUnits+GC::Ref<SVGAnimatedEnumeration> SVGMarkerElement::marker_units()+{+ static constexpr Array keywords {+ SVGAnimatedEnumeration::Keyword { "userSpaceOnUse"sv, SVG_MARKERUNITS_USERSPACEONUSE },+ SVGAnimatedEnumeration::Keyword { "strokeWidth"sv, SVG_MARKERUNITS_STROKEWIDTH },+ };+ return svg_animated_enumeration_for_attribute(AttributeNames::markerUnits, keywords, SVG_MARKERUNITS_STROKEWIDTH);+}++// https://svgwg.org/svg2-draft/painting.html#__svg__SVGMarkerElement__orientType+GC::Ref<SVGAnimatedEnumeration> SVGMarkerElement::orient_type()+{+ // The numeric type values for ‘orient’ are as follows:+ // auto: SVG_MARKER_ORIENT_AUTO+ // auto-start-reverse: SVG_MARKER_ORIENT_AUTO_START_REVERSE+ // <angle> | <number>: SVG_MARKER_ORIENT_ANGLE+ static constexpr Array keywords {+ SVGAnimatedEnumeration::Keyword { "auto"sv, SVG_MARKER_ORIENT_AUTO },+ SVGAnimatedEnumeration::Keyword { "auto-start-reverse"sv, SVG_MARKER_ORIENT_AUTO_START_REVERSE },+ };+ if (!m_orient_type)+ m_orient_type = SVGAnimatedEnumeration::create(*this, AttributeNames::orient, keywords, SVG_MARKER_ORIENT_ANGLE, SVGAnimatedEnumeration::ReflectsOrientType::Yes);+ return *m_orient_type;+}++// https://svgwg.org/svg2-draft/painting.html#__svg__SVGMarkerElement__orientAngle+GC::Ref<SVGAnimatedAngle> SVGMarkerElement::orient_angle()+{+ if (!m_orient_angle) {+ auto base_val = SVGAngle::create_reflected_attribute(*this, AttributeNames::orient, SVGAngle::ReadOnly::No);+ auto anim_val = SVGAngle::create_reflected_attribute(*this, AttributeNames::orient, SVGAngle::ReadOnly::Yes);+ m_orient_angle = SVGAnimatedAngle::create(base_val, anim_val);+ }+ return *m_orient_angle;+}++// https://svgwg.org/svg2-draft/painting.html#__svg__SVGMarkerElement__setOrientToAuto+void SVGMarkerElement::set_orient_to_auto()+{+ // When setOrientToAuto() is called, the ‘orient’ attribute is simply set to 'auto'.+ set_attribute_value(AttributeNames::orient, "auto"_utf16);+}++// https://svgwg.org/svg2-draft/painting.html#__svg__SVGMarkerElement__setOrientToAngle+void SVGMarkerElement::set_orient_to_angle(GC::Ref<SVGAngle> angle)+{+ // When setOrientToAngle(angle) is called, the ‘orient’ attribute is reserialized using angle as the value.+ set_attribute_value(AttributeNames::orient, angle->value_as_string());+}++}diff --git a/Libraries/LibWeb/SVG/SVGMarkerElement.h b/Libraries/LibWeb/SVG/SVGMarkerElement.hnew file mode 100644index 00000000000..9c6a3b48d48--- /dev/null+++ b/Libraries/LibWeb/SVG/SVGMarkerElement.h@@ -0,0 +1,65 @@+/*+ * Copyright (c) 2026-present, the Ladybird developers.+ *+ * SPDX-License-Identifier: BSD-2-Clause+ */++#pragma once++#include <LibWeb/SVG/AttributeNames.h>+#include <LibWeb/SVG/SVGAnimatedAngle.h>+#include <LibWeb/SVG/SVGElement.h>+#include <LibWeb/SVG/SVGFitToViewBox.h>++namespace Web::SVG {++// https://svgwg.org/svg2-draft/painting.html#InterfaceSVGMarkerElement+class SVGMarkerElement final+ : public SVGElement+ , public SVGFitToViewBox {+ WEB_WRAPPABLE(SVGMarkerElement, SVGElement);+ GC_DECLARE_ALLOCATOR(SVGMarkerElement);++public:+ static constexpr u16 SVG_MARKERUNITS_UNKNOWN = 0;+ static constexpr u16 SVG_MARKERUNITS_USERSPACEONUSE = 1;+ static constexpr u16 SVG_MARKERUNITS_STROKEWIDTH = 2;++ static constexpr u16 SVG_MARKER_ORIENT_UNKNOWN = 0;+ static constexpr u16 SVG_MARKER_ORIENT_AUTO = 1;+ static constexpr u16 SVG_MARKER_ORIENT_ANGLE = 2;+ static constexpr u16 SVG_MARKER_ORIENT_AUTO_START_REVERSE = 3;++ virtual ~SVGMarkerElement() override = default;++ // https://svgwg.org/svg2-draft/painting.html#__svg__SVGMarkerElement__refX+ REFLECT_ANIMATED_LENGTH_ATTRIBUTE_WITH_GETTER(refX, ref_x, Horizontal, SVGLengthValue::number(0));++ // https://svgwg.org/svg2-draft/painting.html#__svg__SVGMarkerElement__refY+ REFLECT_ANIMATED_LENGTH_ATTRIBUTE_WITH_GETTER(refY, ref_y, Vertical, SVGLengthValue::number(0));++ // https://svgwg.org/svg2-draft/painting.html#__svg__SVGMarkerElement__markerWidth+ REFLECT_ANIMATED_LENGTH_ATTRIBUTE_WITH_GETTER(markerWidth, marker_width, Horizontal, SVGLengthValue::number(3));++ // https://svgwg.org/svg2-draft/painting.html#__svg__SVGMarkerElement__markerHeight+ REFLECT_ANIMATED_LENGTH_ATTRIBUTE_WITH_GETTER(markerHeight, marker_height, Vertical, SVGLengthValue::number(3));++ GC::Ref<SVGAnimatedEnumeration> marker_units();+ GC::Ref<SVGAnimatedEnumeration> orient_type();+ GC::Ref<SVGAnimatedAngle> orient_angle();++ void set_orient_to_auto();+ void set_orient_to_angle(GC::Ref<SVGAngle>);++private:+ SVGMarkerElement(DOM::Document&, DOM::QualifiedName);++ virtual void initialize_element() override;+ virtual void visit_edges(Cell::Visitor&) override;+ virtual void attribute_changed(Utf16FlyString const& name, Optional<Utf16String> const& old_value, Optional<Utf16String> const& value, Optional<Utf16FlyString> const& namespace_) override;++ GC::Ptr<SVGAnimatedEnumeration> m_orient_type;+ GC::Ptr<SVGAnimatedAngle> m_orient_angle;+};++}diff --git a/Libraries/LibWeb/SVG/SVGMarkerElement.idl b/Libraries/LibWeb/SVG/SVGMarkerElement.idlnew file mode 100644index 00000000000..493e9d4a70b--- /dev/null+++ b/Libraries/LibWeb/SVG/SVGMarkerElement.idl@@ -0,0 +1,29 @@+// https://svgwg.org/svg2-draft/painting.html#InterfaceSVGMarkerElement+[Exposed=Window]+interface SVGMarkerElement : SVGElement {++ // Marker Unit Types+ const unsigned short SVG_MARKERUNITS_UNKNOWN = 0;+ const unsigned short SVG_MARKERUNITS_USERSPACEONUSE = 1;+ const unsigned short SVG_MARKERUNITS_STROKEWIDTH = 2;++ // Marker Orientation Types+ const unsigned short SVG_MARKER_ORIENT_UNKNOWN = 0;+ const unsigned short SVG_MARKER_ORIENT_AUTO = 1;+ const unsigned short SVG_MARKER_ORIENT_ANGLE = 2;+ const unsigned short SVG_MARKER_ORIENT_AUTO_START_REVERSE = 3;++ [SameObject] readonly attribute SVGAnimatedLength refX;+ [SameObject] readonly attribute SVGAnimatedLength refY;+ [SameObject] readonly attribute SVGAnimatedEnumeration markerUnits;+ [SameObject] readonly attribute SVGAnimatedLength markerWidth;+ [SameObject] readonly attribute SVGAnimatedLength markerHeight;+ [SameObject] readonly attribute SVGAnimatedEnumeration orientType;+ [SameObject] readonly attribute SVGAnimatedAngle orientAngle;+ [Reflect] attribute DOMString orient;++ undefined setOrientToAuto();+ undefined setOrientToAngle(SVGAngle angle);+};++SVGMarkerElement includes SVGFitToViewBox;diff --git a/Libraries/LibWeb/SVG/SVGSVGElement.cpp b/Libraries/LibWeb/SVG/SVGSVGElement.cppindex b305d7b3c02..83c786d2d9a 100644--- a/Libraries/LibWeb/SVG/SVGSVGElement.cpp+++ b/Libraries/LibWeb/SVG/SVGSVGElement.cpp@@ -328,6 +328,13 @@ GC::Ref<SVGNumber> SVGSVGElement::create_svg_number() constreturn SVGNumber::create(0, SVGNumber::ReadOnly::No);}+// https://svgwg.org/svg2-draft/struct.html#__svg__SVGSVGElement__createSVGAngle+GC::Ref<SVGAngle> SVGSVGElement::create_svg_angle() const+{+ // A new, detached SVGAngle object whose value is the unitless <number> 0.+ return SVGAngle::create_detached({}, SVGAngle::ReadOnly::No);+}+GC::Ref<SVGLength> SVGSVGElement::create_svg_length() const{// A new, detached SVGLength object whose value is the unitless <number> 0.diff --git a/Libraries/LibWeb/SVG/SVGSVGElement.h b/Libraries/LibWeb/SVG/SVGSVGElement.hindex 417b19c3d7b..8ef322f16b5 100644--- a/Libraries/LibWeb/SVG/SVGSVGElement.h+++ b/Libraries/LibWeb/SVG/SVGSVGElement.h@@ -14,6 +14,7 @@#include <LibWeb/Geometry/DOMRect.h>#include <LibWeb/Geometry/DOMRectReadOnly.h>#include <LibWeb/SVG/AttributeParsing.h>+#include <LibWeb/SVG/SVGAngle.h>#include <LibWeb/SVG/SVGFitToViewBox.h>#include <LibWeb/SVG/SVGGraphicsElement.h>#include <LibWeb/SVG/SVGLength.h>@@ -68,6 +69,7 @@ public:GC::Ref<SVGNumber> create_svg_number() const;GC::Ref<SVGLength> create_svg_length() const;+ GC::Ref<SVGAngle> create_svg_angle() const;GC::Ref<Geometry::DOMPoint> create_svg_point() const;GC::Ref<Geometry::DOMMatrix> create_svg_matrix() const;GC::Ref<Geometry::DOMRect> create_svg_rect() const;diff --git a/Libraries/LibWeb/SVG/SVGSVGElement.idl b/Libraries/LibWeb/SVG/SVGSVGElement.idlindex 29ea7d7a972..a18ba86beee 100644--- a/Libraries/LibWeb/SVG/SVGSVGElement.idl+++ b/Libraries/LibWeb/SVG/SVGSVGElement.idl@@ -18,7 +18,7 @@ interface SVGSVGElement : SVGGraphicsElement {[NewObject] SVGNumber createSVGNumber();[NewObject] SVGLength createSVGLength();- [FIXME, NewObject] SVGAngle createSVGAngle();+ [NewObject] SVGAngle createSVGAngle();[NewObject] DOMPoint createSVGPoint();[NewObject] DOMMatrix createSVGMatrix();[NewObject] DOMRect createSVGRect();diff --git a/Libraries/LibWeb/idl_files.cmake b/Libraries/LibWeb/idl_files.cmakeindex f9da5ff0255..8ff445f9d22 100644--- a/Libraries/LibWeb/idl_files.cmake+++ b/Libraries/LibWeb/idl_files.cmake@@ -493,6 +493,8 @@ libweb_js_bindings(Streams/WritableStreamDefaultController)libweb_js_bindings(Streams/WritableStreamDefaultWriter)libweb_js_bindings(SVG/SVG)libweb_js_bindings(SVG/SVGAElement)+libweb_js_bindings(SVG/SVGAngle)+libweb_js_bindings(SVG/SVGAnimatedAngle)libweb_js_bindings(SVG/SVGAnimatedBoolean)libweb_js_bindings(SVG/SVGAnimatedEnumeration)libweb_js_bindings(SVG/SVGAnimatedInteger)@@ -549,6 +551,7 @@ libweb_js_bindings(SVG/SVGLength)libweb_js_bindings(SVG/SVGLengthList)libweb_js_bindings(SVG/SVGLinearGradientElement)libweb_js_bindings(SVG/SVGLineElement)+libweb_js_bindings(SVG/SVGMarkerElement)libweb_js_bindings(SVG/SVGMaskElement)libweb_js_bindings(SVG/SVGMetadataElement)libweb_js_bindings(SVG/SVGMPathElement)diff --git a/Tests/LibWeb/Text/expected/all-window-properties.txt b/Tests/LibWeb/Text/expected/all-window-properties.txtindex 29861e39ee4..da57430b598 100644--- a/Tests/LibWeb/Text/expected/all-window-properties.txt+++ b/Tests/LibWeb/Text/expected/all-window-properties.txt@@ -401,7 +401,9 @@ ResizeObserverEntryResizeObserverSizeResponseSVGAElement+SVGAngleSVGAnimateMotionElement+SVGAnimatedAngleSVGAnimatedBooleanSVGAnimatedEnumerationSVGAnimatedInteger@@ -456,6 +458,7 @@ SVGLengthListSVGLineElementSVGLinearGradientElementSVGMPathElement+SVGMarkerElementSVGMaskElementSVGMatrixSVGMetadataElementdiff --git a/Tests/LibWeb/Text/expected/wpt-import/svg/idlharness.window.txt b/Tests/LibWeb/Text/expected/wpt-import/svg/idlharness.window.txtindex 4d19695703b..4b491997c01 100644--- a/Tests/LibWeb/Text/expected/wpt-import/svg/idlharness.window.txt+++ b/Tests/LibWeb/Text/expected/wpt-import/svg/idlharness.window.txt@@ -2,8 +2,8 @@ Harness status: OKFound 1780 tests-1219 Pass-561 Fail+1322 Pass+458 FailPass idl_test setupPass idl_test validationPass Partial interface Document: original interface defined@@ -152,43 +152,43 @@ Pass SVGLength interface: objects.svg.createSVGLength() must inherit property "nPass SVGLength interface: calling newValueSpecifiedUnits(unsigned short, float) on objects.svg.createSVGLength() with too few arguments must throw TypeErrorPass SVGLength interface: objects.svg.createSVGLength() must inherit property "convertToSpecifiedUnits(unsigned short)" with the proper typePass SVGLength interface: calling convertToSpecifiedUnits(unsigned short) on objects.svg.createSVGLength() with too few arguments must throw TypeError-Fail SVGAngle interface: existence and properties of interface object-Fail SVGAngle interface object length-Fail SVGAngle interface object name-Fail SVGAngle interface: existence and properties of interface prototype object-Fail SVGAngle interface: existence and properties of interface prototype object's "constructor" property-Fail SVGAngle interface: existence and properties of interface prototype object's @@unscopables property-Fail SVGAngle interface: constant SVG_ANGLETYPE_UNKNOWN on interface object-Fail SVGAngle interface: constant SVG_ANGLETYPE_UNKNOWN on interface prototype object-Fail SVGAngle interface: constant SVG_ANGLETYPE_UNSPECIFIED on interface object-Fail SVGAngle interface: constant SVG_ANGLETYPE_UNSPECIFIED on interface prototype object-Fail SVGAngle interface: constant SVG_ANGLETYPE_DEG on interface object-Fail SVGAngle interface: constant SVG_ANGLETYPE_DEG on interface prototype object-Fail SVGAngle interface: constant SVG_ANGLETYPE_RAD on interface object-Fail SVGAngle interface: constant SVG_ANGLETYPE_RAD on interface prototype object-Fail SVGAngle interface: constant SVG_ANGLETYPE_GRAD on interface object-Fail SVGAngle interface: constant SVG_ANGLETYPE_GRAD on interface prototype object-Fail SVGAngle interface: attribute unitType-Fail SVGAngle interface: attribute value-Fail SVGAngle interface: attribute valueInSpecifiedUnits-Fail SVGAngle interface: attribute valueAsString-Fail SVGAngle interface: operation newValueSpecifiedUnits(unsigned short, float)-Fail SVGAngle interface: operation convertToSpecifiedUnits(unsigned short)-Fail SVGAngle must be primary interface of objects.svg.createSVGAngle()-Fail Stringification of objects.svg.createSVGAngle()-Fail SVGAngle interface: objects.svg.createSVGAngle() must inherit property "SVG_ANGLETYPE_UNKNOWN" with the proper type-Fail SVGAngle interface: objects.svg.createSVGAngle() must inherit property "SVG_ANGLETYPE_UNSPECIFIED" with the proper type-Fail SVGAngle interface: objects.svg.createSVGAngle() must inherit property "SVG_ANGLETYPE_DEG" with the proper type-Fail SVGAngle interface: objects.svg.createSVGAngle() must inherit property "SVG_ANGLETYPE_RAD" with the proper type-Fail SVGAngle interface: objects.svg.createSVGAngle() must inherit property "SVG_ANGLETYPE_GRAD" with the proper type-Fail SVGAngle interface: objects.svg.createSVGAngle() must inherit property "unitType" with the proper type-Fail SVGAngle interface: objects.svg.createSVGAngle() must inherit property "value" with the proper type-Fail SVGAngle interface: objects.svg.createSVGAngle() must inherit property "valueInSpecifiedUnits" with the proper type-Fail SVGAngle interface: objects.svg.createSVGAngle() must inherit property "valueAsString" with the proper type-Fail SVGAngle interface: objects.svg.createSVGAngle() must inherit property "newValueSpecifiedUnits(unsigned short, float)" with the proper type-Fail SVGAngle interface: calling newValueSpecifiedUnits(unsigned short, float) on objects.svg.createSVGAngle() with too few arguments must throw TypeError-Fail SVGAngle interface: objects.svg.createSVGAngle() must inherit property "convertToSpecifiedUnits(unsigned short)" with the proper type-Fail SVGAngle interface: calling convertToSpecifiedUnits(unsigned short) on objects.svg.createSVGAngle() with too few arguments must throw TypeError+Pass SVGAngle interface: existence and properties of interface object+Pass SVGAngle interface object length+Pass SVGAngle interface object name+Pass SVGAngle interface: existence and properties of interface prototype object+Pass SVGAngle interface: existence and properties of interface prototype object's "constructor" property+Pass SVGAngle interface: existence and properties of interface prototype object's @@unscopables property+Pass SVGAngle interface: constant SVG_ANGLETYPE_UNKNOWN on interface object+Pass SVGAngle interface: constant SVG_ANGLETYPE_UNKNOWN on interface prototype object+Pass SVGAngle interface: constant SVG_ANGLETYPE_UNSPECIFIED on interface object+Pass SVGAngle interface: constant SVG_ANGLETYPE_UNSPECIFIED on interface prototype object+Pass SVGAngle interface: constant SVG_ANGLETYPE_DEG on interface object+Pass SVGAngle interface: constant SVG_ANGLETYPE_DEG on interface prototype object+Pass SVGAngle interface: constant SVG_ANGLETYPE_RAD on interface object+Pass SVGAngle interface: constant SVG_ANGLETYPE_RAD on interface prototype object+Pass SVGAngle interface: constant SVG_ANGLETYPE_GRAD on interface object+Pass SVGAngle interface: constant SVG_ANGLETYPE_GRAD on interface prototype object+Pass SVGAngle interface: attribute unitType+Pass SVGAngle interface: attribute value+Pass SVGAngle interface: attribute valueInSpecifiedUnits+Pass SVGAngle interface: attribute valueAsString+Pass SVGAngle interface: operation newValueSpecifiedUnits(unsigned short, float)+Pass SVGAngle interface: operation convertToSpecifiedUnits(unsigned short)+Pass SVGAngle must be primary interface of objects.svg.createSVGAngle()+Pass Stringification of objects.svg.createSVGAngle()+Pass SVGAngle interface: objects.svg.createSVGAngle() must inherit property "SVG_ANGLETYPE_UNKNOWN" with the proper type+Pass SVGAngle interface: objects.svg.createSVGAngle() must inherit property "SVG_ANGLETYPE_UNSPECIFIED" with the proper type+Pass SVGAngle interface: objects.svg.createSVGAngle() must inherit property "SVG_ANGLETYPE_DEG" with the proper type+Pass SVGAngle interface: objects.svg.createSVGAngle() must inherit property "SVG_ANGLETYPE_RAD" with the proper type+Pass SVGAngle interface: objects.svg.createSVGAngle() must inherit property "SVG_ANGLETYPE_GRAD" with the proper type+Pass SVGAngle interface: objects.svg.createSVGAngle() must inherit property "unitType" with the proper type+Pass SVGAngle interface: objects.svg.createSVGAngle() must inherit property "value" with the proper type+Pass SVGAngle interface: objects.svg.createSVGAngle() must inherit property "valueInSpecifiedUnits" with the proper type+Pass SVGAngle interface: objects.svg.createSVGAngle() must inherit property "valueAsString" with the proper type+Pass SVGAngle interface: objects.svg.createSVGAngle() must inherit property "newValueSpecifiedUnits(unsigned short, float)" with the proper type+Pass SVGAngle interface: calling newValueSpecifiedUnits(unsigned short, float) on objects.svg.createSVGAngle() with too few arguments must throw TypeError+Pass SVGAngle interface: objects.svg.createSVGAngle() must inherit property "convertToSpecifiedUnits(unsigned short)" with the proper type+Pass SVGAngle interface: calling convertToSpecifiedUnits(unsigned short) on objects.svg.createSVGAngle() with too few arguments must throw TypeErrorPass SVGNumberList interface: existence and properties of interface objectPass SVGNumberList interface object lengthPass SVGNumberList interface object name@@ -328,18 +328,18 @@ Pass SVGAnimatedLength must be primary interface of objects.svg.xPass Stringification of objects.svg.xPass SVGAnimatedLength interface: objects.svg.x must inherit property "baseVal" with the proper typePass SVGAnimatedLength interface: objects.svg.x must inherit property "animVal" with the proper type-Fail SVGAnimatedAngle interface: existence and properties of interface object-Fail SVGAnimatedAngle interface object length-Fail SVGAnimatedAngle interface object name-Fail SVGAnimatedAngle interface: existence and properties of interface prototype object-Fail SVGAnimatedAngle interface: existence and properties of interface prototype object's "constructor" property-Fail SVGAnimatedAngle interface: existence and properties of interface prototype object's @@unscopables property-Fail SVGAnimatedAngle interface: attribute baseVal-Fail SVGAnimatedAngle interface: attribute animVal-Fail SVGAnimatedAngle must be primary interface of objects.marker.orientAngle-Fail Stringification of objects.marker.orientAngle-Fail SVGAnimatedAngle interface: objects.marker.orientAngle must inherit property "baseVal" with the proper type-Fail SVGAnimatedAngle interface: objects.marker.orientAngle must inherit property "animVal" with the proper type+Pass SVGAnimatedAngle interface: existence and properties of interface object+Pass SVGAnimatedAngle interface object length+Pass SVGAnimatedAngle interface object name+Pass SVGAnimatedAngle interface: existence and properties of interface prototype object+Pass SVGAnimatedAngle interface: existence and properties of interface prototype object's "constructor" property+Pass SVGAnimatedAngle interface: existence and properties of interface prototype object's @@unscopables property+Pass SVGAnimatedAngle interface: attribute baseVal+Pass SVGAnimatedAngle interface: attribute animVal+Pass SVGAnimatedAngle must be primary interface of objects.marker.orientAngle+Pass Stringification of objects.marker.orientAngle+Pass SVGAnimatedAngle interface: objects.marker.orientAngle must inherit property "baseVal" with the proper type+Pass SVGAnimatedAngle interface: objects.marker.orientAngle must inherit property "animVal" with the proper typePass SVGAnimatedString interface: existence and properties of interface objectPass SVGAnimatedString interface object lengthPass SVGAnimatedString interface object name@@ -419,7 +419,7 @@ Pass SVGSVGElement interface: operation checkEnclosure(SVGElement, DOMRectReadOnPass SVGSVGElement interface: operation deselectAll()Pass SVGSVGElement interface: operation createSVGNumber()Pass SVGSVGElement interface: operation createSVGLength()-Fail SVGSVGElement interface: operation createSVGAngle()+Pass SVGSVGElement interface: operation createSVGAngle()Pass SVGSVGElement interface: operation createSVGPoint()Pass SVGSVGElement interface: operation createSVGMatrix()Pass SVGSVGElement interface: operation createSVGRect()@@ -456,7 +456,7 @@ Pass SVGSVGElement interface: calling checkEnclosure(SVGElement, DOMRectReadOnlyPass SVGSVGElement interface: objects.svg must inherit property "deselectAll()" with the proper typePass SVGSVGElement interface: objects.svg must inherit property "createSVGNumber()" with the proper typePass SVGSVGElement interface: objects.svg must inherit property "createSVGLength()" with the proper type-Fail SVGSVGElement interface: objects.svg must inherit property "createSVGAngle()" with the proper type+Pass SVGSVGElement interface: objects.svg must inherit property "createSVGAngle()" with the proper typePass SVGSVGElement interface: objects.svg must inherit property "createSVGPoint()" with the proper typePass SVGSVGElement interface: objects.svg must inherit property "createSVGMatrix()" with the proper typePass SVGSVGElement interface: objects.svg must inherit property "createSVGRect()" with the proper type@@ -1347,59 +1347,59 @@ Pass SVGElement interface: objects.foreignObject must inherit property "ownerSVGPass SVGElement interface: objects.foreignObject must inherit property "viewportElement" with the proper typeFail SVGElement interface: objects.foreignObject must inherit property "correspondingElement" with the proper typeFail SVGElement interface: objects.foreignObject must inherit property "correspondingUseElement" with the proper type-Fail SVGMarkerElement interface: existence and properties of interface object-Fail SVGMarkerElement interface object length-Fail SVGMarkerElement interface object name-Fail SVGMarkerElement interface: existence and properties of interface prototype object-Fail SVGMarkerElement interface: existence and properties of interface prototype object's "constructor" property-Fail SVGMarkerElement interface: existence and properties of interface prototype object's @@unscopables property-Fail SVGMarkerElement interface: constant SVG_MARKERUNITS_UNKNOWN on interface object-Fail SVGMarkerElement interface: constant SVG_MARKERUNITS_UNKNOWN on interface prototype object-Fail SVGMarkerElement interface: constant SVG_MARKERUNITS_USERSPACEONUSE on interface object-Fail SVGMarkerElement interface: constant SVG_MARKERUNITS_USERSPACEONUSE on interface prototype object-Fail SVGMarkerElement interface: constant SVG_MARKERUNITS_STROKEWIDTH on interface object-Fail SVGMarkerElement interface: constant SVG_MARKERUNITS_STROKEWIDTH on interface prototype object-Fail SVGMarkerElement interface: constant SVG_MARKER_ORIENT_UNKNOWN on interface object-Fail SVGMarkerElement interface: constant SVG_MARKER_ORIENT_UNKNOWN on interface prototype object-Fail SVGMarkerElement interface: constant SVG_MARKER_ORIENT_AUTO on interface object-Fail SVGMarkerElement interface: constant SVG_MARKER_ORIENT_AUTO on interface prototype object-Fail SVGMarkerElement interface: constant SVG_MARKER_ORIENT_ANGLE on interface object-Fail SVGMarkerElement interface: constant SVG_MARKER_ORIENT_ANGLE on interface prototype object-Fail SVGMarkerElement interface: constant SVG_MARKER_ORIENT_AUTO_START_REVERSE on interface object-Fail SVGMarkerElement interface: constant SVG_MARKER_ORIENT_AUTO_START_REVERSE on interface prototype object-Fail SVGMarkerElement interface: attribute refX-Fail SVGMarkerElement interface: attribute refY-Fail SVGMarkerElement interface: attribute markerUnits-Fail SVGMarkerElement interface: attribute markerWidth-Fail SVGMarkerElement interface: attribute markerHeight-Fail SVGMarkerElement interface: attribute orientType-Fail SVGMarkerElement interface: attribute orientAngle-Fail SVGMarkerElement interface: attribute orient-Fail SVGMarkerElement interface: operation setOrientToAuto()-Fail SVGMarkerElement interface: operation setOrientToAngle(SVGAngle)-Fail SVGMarkerElement interface: attribute viewBox+Pass SVGMarkerElement interface: existence and properties of interface object+Pass SVGMarkerElement interface object length+Pass SVGMarkerElement interface object name+Pass SVGMarkerElement interface: existence and properties of interface prototype object+Pass SVGMarkerElement interface: existence and properties of interface prototype object's "constructor" property+Pass SVGMarkerElement interface: existence and properties of interface prototype object's @@unscopables property+Pass SVGMarkerElement interface: constant SVG_MARKERUNITS_UNKNOWN on interface object+Pass SVGMarkerElement interface: constant SVG_MARKERUNITS_UNKNOWN on interface prototype object+Pass SVGMarkerElement interface: constant SVG_MARKERUNITS_USERSPACEONUSE on interface object+Pass SVGMarkerElement interface: constant SVG_MARKERUNITS_USERSPACEONUSE on interface prototype object+Pass SVGMarkerElement interface: constant SVG_MARKERUNITS_STROKEWIDTH on interface object+Pass SVGMarkerElement interface: constant SVG_MARKERUNITS_STROKEWIDTH on interface prototype object+Pass SVGMarkerElement interface: constant SVG_MARKER_ORIENT_UNKNOWN on interface object+Pass SVGMarkerElement interface: constant SVG_MARKER_ORIENT_UNKNOWN on interface prototype object+Pass SVGMarkerElement interface: constant SVG_MARKER_ORIENT_AUTO on interface object+Pass SVGMarkerElement interface: constant SVG_MARKER_ORIENT_AUTO on interface prototype object+Pass SVGMarkerElement interface: constant SVG_MARKER_ORIENT_ANGLE on interface object+Pass SVGMarkerElement interface: constant SVG_MARKER_ORIENT_ANGLE on interface prototype object+Pass SVGMarkerElement interface: constant SVG_MARKER_ORIENT_AUTO_START_REVERSE on interface object+Pass SVGMarkerElement interface: constant SVG_MARKER_ORIENT_AUTO_START_REVERSE on interface prototype object+Pass SVGMarkerElement interface: attribute refX+Pass SVGMarkerElement interface: attribute refY+Pass SVGMarkerElement interface: attribute markerUnits+Pass SVGMarkerElement interface: attribute markerWidth+Pass SVGMarkerElement interface: attribute markerHeight+Pass SVGMarkerElement interface: attribute orientType+Pass SVGMarkerElement interface: attribute orientAngle+Pass SVGMarkerElement interface: attribute orient+Pass SVGMarkerElement interface: operation setOrientToAuto()+Pass SVGMarkerElement interface: operation setOrientToAngle(SVGAngle)+Pass SVGMarkerElement interface: attribute viewBoxFail SVGMarkerElement interface: attribute preserveAspectRatio-Fail SVGMarkerElement must be primary interface of objects.marker-Fail Stringification of objects.marker-Fail SVGMarkerElement interface: objects.marker must inherit property "SVG_MARKERUNITS_UNKNOWN" with the proper type-Fail SVGMarkerElement interface: objects.marker must inherit property "SVG_MARKERUNITS_USERSPACEONUSE" with the proper type-Fail SVGMarkerElement interface: objects.marker must inherit property "SVG_MARKERUNITS_STROKEWIDTH" with the proper type-Fail SVGMarkerElement interface: objects.marker must inherit property "SVG_MARKER_ORIENT_UNKNOWN" with the proper type-Fail SVGMarkerElement interface: objects.marker must inherit property "SVG_MARKER_ORIENT_AUTO" with the proper type-Fail SVGMarkerElement interface: objects.marker must inherit property "SVG_MARKER_ORIENT_ANGLE" with the proper type-Fail SVGMarkerElement interface: objects.marker must inherit property "SVG_MARKER_ORIENT_AUTO_START_REVERSE" with the proper type-Fail SVGMarkerElement interface: objects.marker must inherit property "refX" with the proper type-Fail SVGMarkerElement interface: objects.marker must inherit property "refY" with the proper type-Fail SVGMarkerElement interface: objects.marker must inherit property "markerUnits" with the proper type-Fail SVGMarkerElement interface: objects.marker must inherit property "markerWidth" with the proper type-Fail SVGMarkerElement interface: objects.marker must inherit property "markerHeight" with the proper type-Fail SVGMarkerElement interface: objects.marker must inherit property "orientType" with the proper type-Fail SVGMarkerElement interface: objects.marker must inherit property "orientAngle" with the proper type-Fail SVGMarkerElement interface: objects.marker must inherit property "orient" with the proper type-Fail SVGMarkerElement interface: objects.marker must inherit property "setOrientToAuto()" with the proper type-Fail SVGMarkerElement interface: objects.marker must inherit property "setOrientToAngle(SVGAngle)" with the proper type-Fail SVGMarkerElement interface: calling setOrientToAngle(SVGAngle) on objects.marker with too few arguments must throw TypeError-Fail SVGMarkerElement interface: objects.marker must inherit property "viewBox" with the proper type+Pass SVGMarkerElement must be primary interface of objects.marker+Pass Stringification of objects.marker+Pass SVGMarkerElement interface: objects.marker must inherit property "SVG_MARKERUNITS_UNKNOWN" with the proper type+Pass SVGMarkerElement interface: objects.marker must inherit property "SVG_MARKERUNITS_USERSPACEONUSE" with the proper type+Pass SVGMarkerElement interface: objects.marker must inherit property "SVG_MARKERUNITS_STROKEWIDTH" with the proper type+Pass SVGMarkerElement interface: objects.marker must inherit property "SVG_MARKER_ORIENT_UNKNOWN" with the proper type+Pass SVGMarkerElement interface: objects.marker must inherit property "SVG_MARKER_ORIENT_AUTO" with the proper type+Pass SVGMarkerElement interface: objects.marker must inherit property "SVG_MARKER_ORIENT_ANGLE" with the proper type+Pass SVGMarkerElement interface: objects.marker must inherit property "SVG_MARKER_ORIENT_AUTO_START_REVERSE" with the proper type+Pass SVGMarkerElement interface: objects.marker must inherit property "refX" with the proper type+Pass SVGMarkerElement interface: objects.marker must inherit property "refY" with the proper type+Pass SVGMarkerElement interface: objects.marker must inherit property "markerUnits" with the proper type+Pass SVGMarkerElement interface: objects.marker must inherit property "markerWidth" with the proper type+Pass SVGMarkerElement interface: objects.marker must inherit property "markerHeight" with the proper type+Pass SVGMarkerElement interface: objects.marker must inherit property "orientType" with the proper type+Pass SVGMarkerElement interface: objects.marker must inherit property "orientAngle" with the proper type+Pass SVGMarkerElement interface: objects.marker must inherit property "orient" with the proper type+Pass SVGMarkerElement interface: objects.marker must inherit property "setOrientToAuto()" with the proper type+Pass SVGMarkerElement interface: objects.marker must inherit property "setOrientToAngle(SVGAngle)" with the proper type+Pass SVGMarkerElement interface: calling setOrientToAngle(SVGAngle) on objects.marker with too few arguments must throw TypeError+Pass SVGMarkerElement interface: objects.marker must inherit property "viewBox" with the proper typeFail SVGMarkerElement interface: objects.marker must inherit property "preserveAspectRatio" with the proper typePass SVGElement interface: objects.marker must inherit property "className" with the proper typePass SVGElement interface: objects.marker must inherit property "ownerSVGElement" with the proper typediff --git a/Tests/LibWeb/Text/expected/wpt-import/svg/types/SameObject-identity.txt b/Tests/LibWeb/Text/expected/wpt-import/svg/types/SameObject-identity.txtindex de0e02ecb57..e424bd095ca 100644--- a/Tests/LibWeb/Text/expected/wpt-import/svg/types/SameObject-identity.txt+++ b/Tests/LibWeb/Text/expected/wpt-import/svg/types/SameObject-identity.txt@@ -2,8 +2,8 @@ Harness status: ErrorFound 66 tests-63 Pass-3 Fail+64 Pass+2 FailPass SVGAnimatedLength: rect.xPass SVGAnimatedLength: rect.yPass SVGAnimatedLength: rect.width@@ -65,7 +65,7 @@ Pass SVGAnimatedEnumeration: tp.methodPass SVGAnimatedEnumeration: tp.spacingPass SVGAnimatedEnumeration: text.lengthAdjustPass SVGAnimatedAngle: mk.orientAngle-Fail SVGAnimatedAngle.baseVal: mk.orientAngle.baseVal+Pass SVGAnimatedAngle.baseVal: mk.orientAngle.baseValFail SVGAnimatedTransformList: rect.transformFail SVGAnimatedTransformList.baseVal: rect.transform.baseValPass SVGAnimatedTransformList: pat.patternTransformdiff --git a/Tests/LibWeb/Text/expected/wpt-import/svg/types/scripted/SVGAnimatedEnumeration-initial-values.txt b/Tests/LibWeb/Text/expected/wpt-import/svg/types/scripted/SVGAnimatedEnumeration-initial-values.txtindex 6055c864758..4c9a1da0a22 100644--- a/Tests/LibWeb/Text/expected/wpt-import/svg/types/scripted/SVGAnimatedEnumeration-initial-values.txt+++ b/Tests/LibWeb/Text/expected/wpt-import/svg/types/scripted/SVGAnimatedEnumeration-initial-values.txt@@ -1,3 +1,55 @@-Harness status: Error+Harness status: OK-Found 0 tests+Found 50 tests++50 Pass+Pass SVGAnimatedEnumeration, initial values, SVGClipPathElement.prototype.clipPathUnits (remove)+Pass SVGAnimatedEnumeration, initial values, SVGClipPathElement.prototype.clipPathUnits (invalid value)+Pass SVGAnimatedEnumeration, initial values, SVGComponentTransferFunctionElement.prototype.type (remove)+Pass SVGAnimatedEnumeration, initial values, SVGComponentTransferFunctionElement.prototype.type (invalid value)+Pass SVGAnimatedEnumeration, initial values, SVGFEBlendElement.prototype.mode (remove)+Pass SVGAnimatedEnumeration, initial values, SVGFEBlendElement.prototype.mode (invalid value)+Pass SVGAnimatedEnumeration, initial values, SVGFEColorMatrixElement.prototype.type (remove)+Pass SVGAnimatedEnumeration, initial values, SVGFEColorMatrixElement.prototype.type (invalid value)+Pass SVGAnimatedEnumeration, initial values, SVGFECompositeElement.prototype.operator (remove)+Pass SVGAnimatedEnumeration, initial values, SVGFECompositeElement.prototype.operator (invalid value)+Pass SVGAnimatedEnumeration, initial values, SVGFEConvolveMatrixElement.prototype.edgeMode (remove)+Pass SVGAnimatedEnumeration, initial values, SVGFEConvolveMatrixElement.prototype.edgeMode (invalid value)+Pass SVGAnimatedEnumeration, initial values, SVGFEDisplacementMapElement.prototype.xChannelSelector (remove)+Pass SVGAnimatedEnumeration, initial values, SVGFEDisplacementMapElement.prototype.xChannelSelector (invalid value)+Pass SVGAnimatedEnumeration, initial values, SVGFEDisplacementMapElement.prototype.yChannelSelector (remove)+Pass SVGAnimatedEnumeration, initial values, SVGFEDisplacementMapElement.prototype.yChannelSelector (invalid value)+Pass SVGAnimatedEnumeration, initial values, SVGFEGaussianBlurElement.prototype.edgeMode (remove)+Pass SVGAnimatedEnumeration, initial values, SVGFEGaussianBlurElement.prototype.edgeMode (invalid value)+Pass SVGAnimatedEnumeration, initial values, SVGFEMorphologyElement.prototype.operator (remove)+Pass SVGAnimatedEnumeration, initial values, SVGFEMorphologyElement.prototype.operator (invalid value)+Pass SVGAnimatedEnumeration, initial values, SVGFETurbulenceElement.prototype.stitchTiles (remove)+Pass SVGAnimatedEnumeration, initial values, SVGFETurbulenceElement.prototype.stitchTiles (invalid value)+Pass SVGAnimatedEnumeration, initial values, SVGFETurbulenceElement.prototype.type (remove)+Pass SVGAnimatedEnumeration, initial values, SVGFETurbulenceElement.prototype.type (invalid value)+Pass SVGAnimatedEnumeration, initial values, SVGFilterElement.prototype.filterUnits (remove)+Pass SVGAnimatedEnumeration, initial values, SVGFilterElement.prototype.filterUnits (invalid value)+Pass SVGAnimatedEnumeration, initial values, SVGFilterElement.prototype.primitiveUnits (remove)+Pass SVGAnimatedEnumeration, initial values, SVGFilterElement.prototype.primitiveUnits (invalid value)+Pass SVGAnimatedEnumeration, initial values, SVGGradientElement.prototype.gradientUnits (remove)+Pass SVGAnimatedEnumeration, initial values, SVGGradientElement.prototype.gradientUnits (invalid value)+Pass SVGAnimatedEnumeration, initial values, SVGGradientElement.prototype.spreadMethod (remove)+Pass SVGAnimatedEnumeration, initial values, SVGGradientElement.prototype.spreadMethod (invalid value)+Pass SVGAnimatedEnumeration, initial values, SVGMarkerElement.prototype.markerUnits (remove)+Pass SVGAnimatedEnumeration, initial values, SVGMarkerElement.prototype.markerUnits (invalid value)+Pass SVGAnimatedEnumeration, initial values, SVGMarkerElement.prototype.orientType (remove)+Pass SVGAnimatedEnumeration, initial values, SVGMarkerElement.prototype.orientType (invalid value)+Pass SVGAnimatedEnumeration, initial values, SVGMaskElement.prototype.maskUnits (remove)+Pass SVGAnimatedEnumeration, initial values, SVGMaskElement.prototype.maskUnits (invalid value)+Pass SVGAnimatedEnumeration, initial values, SVGMaskElement.prototype.maskContentUnits (remove)+Pass SVGAnimatedEnumeration, initial values, SVGMaskElement.prototype.maskContentUnits (invalid value)+Pass SVGAnimatedEnumeration, initial values, SVGPatternElement.prototype.patternUnits (remove)+Pass SVGAnimatedEnumeration, initial values, SVGPatternElement.prototype.patternUnits (invalid value)+Pass SVGAnimatedEnumeration, initial values, SVGPatternElement.prototype.patternContentUnits (remove)+Pass SVGAnimatedEnumeration, initial values, SVGPatternElement.prototype.patternContentUnits (invalid value)+Pass SVGAnimatedEnumeration, initial values, SVGTextContentElement.prototype.lengthAdjust (remove)+Pass SVGAnimatedEnumeration, initial values, SVGTextContentElement.prototype.lengthAdjust (invalid value)+Pass SVGAnimatedEnumeration, initial values, SVGTextPathElement.prototype.method (remove)+Pass SVGAnimatedEnumeration, initial values, SVGTextPathElement.prototype.method (invalid value)+Pass SVGAnimatedEnumeration, initial values, SVGTextPathElement.prototype.spacing (remove)+Pass SVGAnimatedEnumeration, initial values, SVGTextPathElement.prototype.spacing (invalid value)\ No newline at end of filediff --git a/Tests/LibWeb/Text/expected/wpt-import/svg/types/scripted/SVGAnimatedEnumeration-invalid-values.txt b/Tests/LibWeb/Text/expected/wpt-import/svg/types/scripted/SVGAnimatedEnumeration-invalid-values.txtindex 94cd9349d86..359432e8d5e 100644--- a/Tests/LibWeb/Text/expected/wpt-import/svg/types/scripted/SVGAnimatedEnumeration-invalid-values.txt+++ b/Tests/LibWeb/Text/expected/wpt-import/svg/types/scripted/SVGAnimatedEnumeration-invalid-values.txt@@ -2,8 +2,7 @@ Harness status: OKFound 52 tests-48 Pass-4 Fail+52 PassPass SVGAnimatedEnumeration, invalid values, SVGClipPathElement.prototype.clipPathUnits (empty string)Pass SVGAnimatedEnumeration, invalid values, SVGClipPathElement.prototype.clipPathUnits (content attribute is not rewritten)Pass SVGAnimatedEnumeration, invalid values, SVGComponentTransferFunctionElement.prototype.type (empty string)@@ -36,10 +35,10 @@ Pass SVGAnimatedEnumeration, invalid values, SVGGradientElement.prototype.gradiePass SVGAnimatedEnumeration, invalid values, SVGGradientElement.prototype.gradientUnits (content attribute is not rewritten)Pass SVGAnimatedEnumeration, invalid values, SVGGradientElement.prototype.spreadMethod (empty string)Pass SVGAnimatedEnumeration, invalid values, SVGGradientElement.prototype.spreadMethod (content attribute is not rewritten)-Fail SVGAnimatedEnumeration, invalid values, SVGMarkerElement.prototype.markerUnits (empty string)-Fail SVGAnimatedEnumeration, invalid values, SVGMarkerElement.prototype.markerUnits (content attribute is not rewritten)-Fail SVGAnimatedEnumeration, invalid values, SVGMarkerElement.prototype.orientType (empty string)-Fail SVGAnimatedEnumeration, invalid values, SVGMarkerElement.prototype.orientType (content attribute is not rewritten)+Pass SVGAnimatedEnumeration, invalid values, SVGMarkerElement.prototype.markerUnits (empty string)+Pass SVGAnimatedEnumeration, invalid values, SVGMarkerElement.prototype.markerUnits (content attribute is not rewritten)+Pass SVGAnimatedEnumeration, invalid values, SVGMarkerElement.prototype.orientType (empty string)+Pass SVGAnimatedEnumeration, invalid values, SVGMarkerElement.prototype.orientType (content attribute is not rewritten)Pass SVGAnimatedEnumeration, invalid values, SVGMaskElement.prototype.maskUnits (empty string)Pass SVGAnimatedEnumeration, invalid values, SVGMaskElement.prototype.maskUnits (content attribute is not rewritten)Pass SVGAnimatedEnumeration, invalid values, SVGMaskElement.prototype.maskContentUnits (empty string)diff --git a/Tests/LibWeb/Text/expected/wpt-import/svg/types/scripted/SVGAnimatedEnumeration-keywords.txt b/Tests/LibWeb/Text/expected/wpt-import/svg/types/scripted/SVGAnimatedEnumeration-keywords.txtindex 853f283ae09..4f4ff09914c 100644--- a/Tests/LibWeb/Text/expected/wpt-import/svg/types/scripted/SVGAnimatedEnumeration-keywords.txt+++ b/Tests/LibWeb/Text/expected/wpt-import/svg/types/scripted/SVGAnimatedEnumeration-keywords.txt@@ -2,8 +2,7 @@ Harness status: OKFound 32 tests-30 Pass-2 Fail+32 PassPass SVGAnimatedEnumeration, keyword values, SVGComponentTransferFunctionElement.prototype.type (keywords)Pass SVGAnimatedEnumeration, keyword values, SVGComponentTransferFunctionElement.prototype.type (case-sensitive)Pass SVGAnimatedEnumeration, keyword values, SVGFEBlendElement.prototype.mode (keywords)@@ -28,8 +27,8 @@ Pass SVGAnimatedEnumeration, keyword values, SVGGradientElement.prototype.spreadPass SVGAnimatedEnumeration, keyword values, SVGGradientElement.prototype.spreadMethod (case-sensitive)Pass SVGAnimatedEnumeration, keyword values, SVGGradientElement.prototype.gradientUnits (keywords)Pass SVGAnimatedEnumeration, keyword values, SVGGradientElement.prototype.gradientUnits (case-sensitive)-Fail SVGAnimatedEnumeration, keyword values, SVGMarkerElement.prototype.markerUnits (keywords)-Fail SVGAnimatedEnumeration, keyword values, SVGMarkerElement.prototype.markerUnits (case-sensitive)+Pass SVGAnimatedEnumeration, keyword values, SVGMarkerElement.prototype.markerUnits (keywords)+Pass SVGAnimatedEnumeration, keyword values, SVGMarkerElement.prototype.markerUnits (case-sensitive)Pass SVGAnimatedEnumeration, keyword values, SVGTextContentElement.prototype.lengthAdjust (keywords)Pass SVGAnimatedEnumeration, keyword values, SVGTextContentElement.prototype.lengthAdjust (case-sensitive)Pass SVGAnimatedEnumeration, keyword values, SVGTextPathElement.prototype.method (keywords)diff --git a/Tests/LibWeb/Text/expected/wpt-import/svg/types/scripted/SVGAnimatedLength-initial-values.txt b/Tests/LibWeb/Text/expected/wpt-import/svg/types/scripted/SVGAnimatedLength-initial-values.txtindex 39da74ca2bb..ea272a12363 100644--- a/Tests/LibWeb/Text/expected/wpt-import/svg/types/scripted/SVGAnimatedLength-initial-values.txt+++ b/Tests/LibWeb/Text/expected/wpt-import/svg/types/scripted/SVGAnimatedLength-initial-values.txt@@ -2,8 +2,8 @@ Harness status: OKFound 130 tests-120 Pass-10 Fail+128 Pass+2 FailPass SVGAnimatedLength, initial values, SVGCircleElement.prototype.cx (remove)Pass SVGAnimatedLength, initial values, SVGCircleElement.prototype.cx (invalid value)Pass SVGAnimatedLength, initial values, SVGCircleElement.prototype.cy (remove)@@ -66,14 +66,14 @@ Pass SVGAnimatedLength, initial values, SVGLinearGradientElement.prototype.x2 (rPass SVGAnimatedLength, initial values, SVGLinearGradientElement.prototype.x2 (invalid value)Pass SVGAnimatedLength, initial values, SVGLinearGradientElement.prototype.y2 (remove)Pass SVGAnimatedLength, initial values, SVGLinearGradientElement.prototype.y2 (invalid value)-Fail SVGAnimatedLength, initial values, SVGMarkerElement.prototype.refX (remove)-Fail SVGAnimatedLength, initial values, SVGMarkerElement.prototype.refX (invalid value)-Fail SVGAnimatedLength, initial values, SVGMarkerElement.prototype.refY (remove)-Fail SVGAnimatedLength, initial values, SVGMarkerElement.prototype.refY (invalid value)-Fail SVGAnimatedLength, initial values, SVGMarkerElement.prototype.markerWidth (remove)-Fail SVGAnimatedLength, initial values, SVGMarkerElement.prototype.markerWidth (invalid value)-Fail SVGAnimatedLength, initial values, SVGMarkerElement.prototype.markerHeight (remove)-Fail SVGAnimatedLength, initial values, SVGMarkerElement.prototype.markerHeight (invalid value)+Pass SVGAnimatedLength, initial values, SVGMarkerElement.prototype.refX (remove)+Pass SVGAnimatedLength, initial values, SVGMarkerElement.prototype.refX (invalid value)+Pass SVGAnimatedLength, initial values, SVGMarkerElement.prototype.refY (remove)+Pass SVGAnimatedLength, initial values, SVGMarkerElement.prototype.refY (invalid value)+Pass SVGAnimatedLength, initial values, SVGMarkerElement.prototype.markerWidth (remove)+Pass SVGAnimatedLength, initial values, SVGMarkerElement.prototype.markerWidth (invalid value)+Pass SVGAnimatedLength, initial values, SVGMarkerElement.prototype.markerHeight (remove)+Pass SVGAnimatedLength, initial values, SVGMarkerElement.prototype.markerHeight (invalid value)Pass SVGAnimatedLength, initial values, SVGMaskElement.prototype.x (remove)Pass SVGAnimatedLength, initial values, SVGMaskElement.prototype.x (invalid value)Pass SVGAnimatedLength, initial values, SVGMaskElement.prototype.y (remove)