diff --git a/Libraries/LibWeb/CSS/CSSStyleProperties.cpp b/Libraries/LibWeb/CSS/CSSStyleProperties.cpp index 921d02a11b4..97e83f23b87 100644 --- a/Libraries/LibWeb/CSS/CSSStyleProperties.cpp +++ b/Libraries/LibWeb/CSS/CSSStyleProperties.cpp @@ -813,10 +813,6 @@ RefPtr CSSStyleProperties::style_value_for_computed_property(L return get_computed_value(property_id); } - case PropertyID::FillOpacity: { - auto opacity = layout_node.computed_values().fill_opacity(); - return NumberStyleValue::create(opacity); - } case PropertyID::StopOpacity: { auto opacity = layout_node.computed_values().stop_opacity(); return NumberStyleValue::create(opacity); diff --git a/Libraries/LibWeb/CSS/ComputedProperties.cpp b/Libraries/LibWeb/CSS/ComputedProperties.cpp index d14997ecc83..1afd20f44a1 100644 --- a/Libraries/LibWeb/CSS/ComputedProperties.cpp +++ b/Libraries/LibWeb/CSS/ComputedProperties.cpp @@ -479,8 +479,7 @@ float ComputedProperties::opacity() const float ComputedProperties::fill_opacity() const { - auto const& value = property(PropertyID::FillOpacity); - return resolve_opacity_value(value); + return property(PropertyID::FillOpacity).as_number().number(); } StrokeLinecap ComputedProperties::stroke_linecap() const diff --git a/Libraries/LibWeb/CSS/StyleComputer.cpp b/Libraries/LibWeb/CSS/StyleComputer.cpp index ec14e885a55..ba7b52e1df8 100644 --- a/Libraries/LibWeb/CSS/StyleComputer.cpp +++ b/Libraries/LibWeb/CSS/StyleComputer.cpp @@ -3283,6 +3283,7 @@ NonnullRefPtr StyleComputer::compute_value_of_property(Propert return compute_border_or_outline_width(specified_value, get_property_specified_value(PropertyID::BorderTopStyle), computation_context); case PropertyID::OutlineWidth: return compute_border_or_outline_width(specified_value, get_property_specified_value(PropertyID::OutlineStyle), computation_context); + case PropertyID::FillOpacity: case PropertyID::Opacity: return compute_opacity(specified_value, computation_context); default: