Jesslen• 20
@Jessilen20
Submitted
I had problems with the state of the rating buttons. They only work correctly when I hold down the button, but when I select it, its style doesn't change. Is this ok?
@tonchi5
@Jessilen20
Submitted
I had problems with the state of the rating buttons. They only work correctly when I hold down the button, but when I select it, its style doesn't change. Is this ok?
@tonchi5
Posted
Hey, you could add pseudoclass :focus in your css to the rating buttons(rating-buttons:focus{color: gray}) to keep the color gray on the selected button, it keeps the gray color until you click somewhere else. You can center the container on the page with position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); Hope this helps :)
Marked as helpful