From d299040d55b41e840d6e4499ee1b9ea8ee96fcac Mon Sep 17 00:00:00 2001 From: Jonathan Kew Date: Sat, 27 May 2023 06:10:30 +0200 Subject: [PATCH] style: Fix the serialization order for the text-decoration shorthand to match the canonical order in the spec Differential Revision: https://phabricator.services.mozilla.com/D124536 --- .../style/properties/shorthands/text.mako.rs | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/components/style/properties/shorthands/text.mako.rs b/components/style/properties/shorthands/text.mako.rs index 03637d557e5..5e71fc08cf3 100644 --- a/components/style/properties/shorthands/text.mako.rs +++ b/components/style/properties/shorthands/text.mako.rs @@ -88,6 +88,13 @@ has_value = true; } + if !is_auto_thickness { + if has_value { + dest.write_str(" ")?; + } + self.text_decoration_thickness.to_css(dest)?; + } + % if engine == "gecko": if !is_solid_style { if has_value { @@ -104,13 +111,6 @@ self.text_decoration_color.to_css(dest)?; has_value = true; } - - if !is_auto_thickness { - if has_value { - dest.write_str(" ")?; - } - self.text_decoration_thickness.to_css(dest)?; - } % endif Ok(())