From 766feec4c09c9d8ead9eedcb409d303dea7363ce Mon Sep 17 00:00:00 2001 From: Xidorn Quan Date: Wed, 24 May 2017 20:27:18 +1000 Subject: [PATCH] Reject "text" value in background shorthand. --- components/style/properties/shorthand/background.mako.rs | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/components/style/properties/shorthand/background.mako.rs b/components/style/properties/shorthand/background.mako.rs index b4f3f9fe079..58f0361cffa 100644 --- a/components/style/properties/shorthand/background.mako.rs +++ b/components/style/properties/shorthand/background.mako.rs @@ -69,6 +69,13 @@ if ${name}.is_none() { if let Ok(value) = input.try(|input| background_${name}::single_value ::parse(context, input)) { + % if name == "clip" and product == "gecko": + // "text" value of background-clip should not be part of background + // shorthand per current spec and impls. + if value == background_clip::single_value::SpecifiedValue::text { + return Err(()); + } + % endif ${name} = Some(value); continue }