CSS Animation to Change the Hover State of a Button

@keyframes rule should use the animation-name background-color

Your code so far


<style>
button {
  border-radius: 5px;
  color: white;
  background-color: #0F5897;
  padding: 5px 10px 8px 10px;
}

button:hover {
  animation-name: background-color;
  animation-duration: 500ms;
}
@keyframes background
100% {
background-color: #4791d0;
}
@keyframes{
animation-name: background-color;
}
</style>

<button>Register</button>

Your browser information:

User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/81.0.4044.129 Safari/537.36.

Challenge: Use CSS Animation to Change the Hover State of a Button

Link to the challenge:

@keyframes should use the name background-color.
You are missing your opening { and closing } for your @keyframes element.

can u plz write it .Coz i didn’t understand.

Your first written @keyframes should have background-color and you are missing the opening { curly brace.