diff --git a/Userland/Libraries/LibWeb/CSS/StyleValue.h b/Userland/Libraries/LibWeb/CSS/StyleValue.h index 400586ac54..1205753016 100644 --- a/Userland/Libraries/LibWeb/CSS/StyleValue.h +++ b/Userland/Libraries/LibWeb/CSS/StyleValue.h @@ -348,6 +348,13 @@ public: float value() const { return m_value; } String to_string() const override { return String::formatted("{}", m_value); } + virtual bool equals(StyleValue const& other) const override + { + if (type() != other.type()) + return false; + return m_value == static_cast(other).m_value; + } + private: explicit NumericStyleValue(float value) : StyleValue(Type::Numeric)