From cbd746e3ecb69a2fc00aa543ae22df9ee94bd04f Mon Sep 17 00:00:00 2001 From: Linus Groh Date: Wed, 13 May 2020 17:18:36 +0100 Subject: [PATCH] LibWeb: Support "transparent" CSS color value --- Libraries/LibWeb/Parser/CSSParser.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Libraries/LibWeb/Parser/CSSParser.cpp b/Libraries/LibWeb/Parser/CSSParser.cpp index 5fe882fc82..7820209ae7 100644 --- a/Libraries/LibWeb/Parser/CSSParser.cpp +++ b/Libraries/LibWeb/Parser/CSSParser.cpp @@ -43,6 +43,9 @@ namespace Web { static Optional parse_css_color(const StringView& view) { + if (view.equals_ignoring_case("transparent")) + return Color::from_rgba(0x00000000); + auto color = Color::from_string(view.to_string().to_lowercase()); if (color.has_value()) return color;