LibWeb/CSS: Absolutize GradientStyleValues

This lets us not care about non-absolute Length units when resolving
gradient data, as they'll already have been converted to px.

We can also use Angle::from_style_value() safely on absolutized angles,
which reduces some boilerplate code.
This commit is contained in:
Sam Atkins
2025-11-20 17:16:15 +00:00
parent fbe0567f90
commit f81bb1bd8c
Notes: github-actions[bot] 2025-12-01 11:09:51 +00:00
10 changed files with 205 additions and 161 deletions

View File

@@ -172,6 +172,7 @@ struct ColorStopListElement {
} color_stop;
bool operator==(ColorStopListElement const&) const = default;
ColorStopListElement absolutized(ComputationContext const& context) const;
};
void serialize_color_stop_list(StringBuilder&, Vector<ColorStopListElement> const&, SerializationMode);