From e850d9572a023b07b3b72b6014f28ca7e5f66610 Mon Sep 17 00:00:00 2001 From: Xidorn Quan Date: Tue, 28 Feb 2017 17:17:54 +1100 Subject: [PATCH] Don't serialize currentcolor for border shorthand --- components/style/properties/shorthand/serialize.mako.rs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/components/style/properties/shorthand/serialize.mako.rs b/components/style/properties/shorthand/serialize.mako.rs index 017e77586eb..660c455f027 100644 --- a/components/style/properties/shorthand/serialize.mako.rs +++ b/components/style/properties/shorthand/serialize.mako.rs @@ -2,6 +2,7 @@ * License, v. 2.0. If a copy of the MPL was not distributed with this * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ +use cssparser::Color; use properties::DeclaredValue; use style_traits::ToCss; use values::specified::{BorderStyle, CSSColor}; @@ -84,7 +85,7 @@ fn serialize_directional_border(dest: &mut W, }; match *color { - DeclaredValue::Value(ref color) => { + DeclaredValue::Value(ref color) if color.parsed != Color::CurrentColor => { try!(write!(dest, " ")); color.to_css(dest) },