Bug 1356941 - Use IntermediateColor for text-shadow. r?birtles
MozReview-Commit-ID: 6jE3VFdV7kB
--- a/servo/components/style/properties/helpers/animated_properties.mako.rs
+++ b/servo/components/style/properties/helpers/animated_properties.mako.rs
@@ -2225,16 +2225,17 @@ impl Interpolate for IntermediateRGBA {
}
}
}
${impl_interpolate_for_shadow('Intermediate%sShadow' % type,
'IntermediateColor::IntermediateRGBA(IntermediateRGBA::transparent())')}
</%def>
${impl_intermediate_type_for_shadow('Box')}
+${impl_intermediate_type_for_shadow('Text')}
impl<'a> From<<&'a Either<CSSParserColor, Auto>> for Either<IntermediateColor, Auto> {
fn from(from: &Either<CSSParserColor, Auto>) -> Either<IntermediateColor, Auto> {
match *from {
Either::First(ref from) =>
match *from {
CSSParserColor::RGBA(ref color) =>
Either::First(IntermediateColor::IntermediateRGBA(
--- a/servo/components/style/properties/longhand/inherited_text.mako.rs
+++ b/servo/components/style/properties/longhand/inherited_text.mako.rs
@@ -706,17 +706,18 @@
SpecifiedValue::pre |
SpecifiedValue::pre_wrap => true,
}
}
}
% endif
</%helpers:single_keyword_computed>
-<%helpers:longhand name="text-shadow" animation_value_type="ComputedValue"
+<%helpers:longhand name="text-shadow"
+ animation_value_type="IntermediateTextShadowList",
spec="https://drafts.csswg.org/css-text-decor/#propdef-text-shadow">
use cssparser;
use std::fmt;
use style_traits::ToCss;
use values::HasViewportPercentage;
impl HasViewportPercentage for SpecifiedValue {
fn has_viewport_percentage(&self) -> bool {