Looking at the W3C CSS Animations WD , the syntax for the shorthand animation property is:
[<animation-name> || <animation-duration> || <animation-timing-function> || <animation-delay> || <animation-iteration-count> || <animation-direction> || <animation-fill-mode>] [, [<animation-name> || <animation-duration> || <animation-timing-function> || <animation-delay> || <animation-iteration-count> || <animation-direction> || <animation-fill-mode>] ]*
The value accepts only the animation-name , which is used to select a keyframe that provides property values for the animation, then with other parameters that determine how these rules should be followed.
There is currently no string syntax defined in the specifications that would allow you to define an embedded keyframe framework; you need to reference an existing one using the animation-name property. From the specifications :
The 'animation-name' property determines the list of animations used. Each name is used to select a keyframe in the rule, which provides property values for the animation. If the name does not match any keyframe, there are no properties that need to be animated and the animation will not run.
Fabrício matté
source share