mirror of
https://github.com/servo/servo.git
synced 2025-08-10 07:55:33 +01:00
style: Add support to the animation shorthand and fix parsing of animation-name.
This commit is contained in:
parent
4fafcb121f
commit
411ae84908
5 changed files with 194 additions and 46 deletions
|
@ -235,11 +235,21 @@
|
|||
}
|
||||
}
|
||||
|
||||
pub use self::computed_value::${to_camel_case(name)} as SingleSpecifiedValue;
|
||||
|
||||
#[inline]
|
||||
pub fn parse_one(input: &mut Parser) -> Result<SingleSpecifiedValue, ()> {
|
||||
SingleSpecifiedValue::parse(input)
|
||||
}
|
||||
|
||||
#[inline]
|
||||
pub fn get_initial_value() -> computed_value::T {
|
||||
computed_value::T(vec![
|
||||
computed_value::${to_camel_case(name)}::${to_rust_ident(values.split()[0])}
|
||||
])
|
||||
computed_value::T(vec![get_initial_single_value()])
|
||||
}
|
||||
|
||||
#[inline]
|
||||
pub fn get_initial_single_value() -> SingleSpecifiedValue {
|
||||
SingleSpecifiedValue::${to_rust_ident(values.split()[0])}
|
||||
}
|
||||
|
||||
#[inline]
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue