Add clip-path

This commit is contained in:
Manish Goregaokar 2016-08-15 15:16:06 +05:30
parent 254900bd1a
commit 1d32422fe8

View file

@ -49,3 +49,31 @@ ${helpers.predefined_type(
// https://www.w3.org/TR/css-masking-1/
${helpers.single_keyword("mask-type", "luminance alpha",
products="gecko", animatable=False)}
<%helpers:longhand name="clip-path" animatable="False" products="gecko">
use cssparser::ToCss;
use std::fmt;
use values::LocalToCss;
use values::NoViewportPercentage;
use values::specified::basic_shape::{ShapeSource, GeometryBox};
pub mod computed_value {
use app_units::Au;
use values::computed::basic_shape::{ShapeSource, GeometryBox};
pub type T = ShapeSource<GeometryBox>;
}
pub type SpecifiedValue = ShapeSource<GeometryBox>;
#[inline]
pub fn get_initial_value() -> computed_value::T {
Default::default()
}
pub fn parse(context: &ParserContext, input: &mut Parser) -> Result<SpecifiedValue, ()> {
ShapeSource::parse(context, input)
}
impl NoViewportPercentage for SpecifiedValue {}
</%helpers:longhand>