LibWeb: Don't convert color functions to RGB when resolving color values

This commit is contained in:
Tim Ledbetter 2025-04-05 23:27:50 +01:00 committed by Sam Atkins
commit a97fe3123d
Notes: github-actions[bot] 2025-04-09 11:12:39 +00:00
5 changed files with 746 additions and 10 deletions

View file

@ -21,6 +21,8 @@ public:
virtual Color to_color(Optional<Layout::NodeWithStyle const&>) const override;
virtual String to_string(SerializationMode) const override;
virtual bool is_color_function() const override { return true; }
static constexpr Array s_supported_color_space = { "a98-rgb"sv, "display-p3"sv, "srgb"sv, "srgb-linear"sv, "prophoto-rgb"sv, "rec2020"sv, "xyz"sv, "xyz-d50"sv, "xyz-d65"sv };
private: