LibWeb: Remove LightDark and ColorMix from the ColorType enum

This commit is contained in:
Tim Ledbetter
2026-04-20 08:31:10 +01:00
committed by Sam Atkins
parent e4c29811be
commit 53a0991ff5
Notes: github-actions[bot] 2026-04-22 10:54:47 +00:00
9 changed files with 43 additions and 38 deletions

View File

@@ -634,7 +634,8 @@ static RefPtr<StyleValue const> resolve_color_style_value(StyleValue const& styl
return style_value;
if (style_value.is_color()) {
auto& color_style_value = static_cast<ColorStyleValue const&>(style_value);
if (first_is_one_of(color_style_value.color_type(), ColorStyleValue::ColorType::Lab, ColorStyleValue::ColorType::OKLab, ColorStyleValue::ColorType::LCH, ColorStyleValue::ColorType::OKLCH))
if (auto color_type = color_style_value.color_type();
color_type.has_value() && first_is_one_of(*color_type, ColorStyleValue::ColorType::Lab, ColorStyleValue::ColorType::OKLab, ColorStyleValue::ColorType::LCH, ColorStyleValue::ColorType::OKLCH))
return style_value;
}