CSS

CSS Intro

CSS Intro Quiz

CSS Intro Exercise

CSS Basic

CSS Basic Quiz

CSS Basic Exercise

CSS Advance

CSS Advance Quiz

CSS Advance Exercise

CSS3

CSS3 Quiz

CSS3 Exercise

CSS Properties

CSS Functions

CSS Selectors

Animation in CSS

Animations CSS

 

 

An animation lets an element gradually change from one state to another. Keyframes hold the styles the element will have at certain times. It starts from 0% to 100%. We can add as many properties as we want to it. To make an animation work, we have to bind it with elements. It is a Short Hand Property.

 

Animation property consists of:-

 

  1. animation-name
  2. animation-duration
  3. animation-timing-function
  4. animation-delay
  5. animation-iteration-count
  6. animation-direction
  7. animation-fill-mode
  8. animation-play-state

 

Syntax:-

 

Its syntax is:-

< style >

element{

animation: name duration timing-function delay iteration-count direction fill-mode play-state;

}

< /style >

 

Further Explanation:-

 

Value Description
animation-name Specifies the name of the keyframe you want to bind to the selector
animation-duration Specifies how many seconds or milliseconds an animation takes to complete
animation-timing-function Specifies the speed curve of the animation
animation-delay Specifies delay before the animation will start
animation-iteration-count Specifies how many times an animation should be played
animation-direction Specifies whether or not the animation should play in reverse on alternate cycles
animation-fill-mode Specifies what values are applied by the animation outside the time it is executing
animation-play-state Specifies whether the animation is running or paused
initial Sets this property to its default value.
inherit Inherits this property from its parent element.

Code Explanation

All Tutorials related to CSS3

All Sections related to CSS