New! My 44-page ebook "CSS in 44 minutes" is out! 😃

Get it now →

#transition

Shorthand property for transition-property transition-duration transition-timing-function and transition-delay.

Only transition-duration is required.

transition: 1s;

  • transition-duration is set to 1s
  • transition-property defaults to all
  • transition-timing-function defaults to ease
  • transition-delay defaults to 0s

transition: 1s linear;

  • transition-duration is set to 1s
  • transition-property defaults to all
  • transition-timing-function is set to linear
  • transition-delay defaults to 0s

transition: background 1s linear;

  • transition-duration is set to 1s
  • transition-property is set to background
  • transition-timing-function is set to linear
  • transition-delay defaults to 0s

transition: background 1s linear 500ms;

  • transition-duration is set to 1s
  • transition-property is set to background
  • transition-timing-function is set to linear
  • transition-delay is set to 500ms

transition: background 4s, transform 1s;

You can combine multiple properties with their own transition duration.