You should give hovered li elements a background-color of #dfdfe2
li > a {
color: inherit;
text-decoration: none;
hover:
}
li {background-color: #dfdfe2;
}
As far as I can tell I did exactly that and the li elements are shaded in the output. I must be missing something…
Thanks for taking a look at what I’m doing…
User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/113.0.0.0 Safari/537.36
Challenge: Learn Accessibility by Building a Quiz - Step 47
Link to the challenge:
You have to use a pseudo selector to apply the styling when you hover the cursor.
So, you can use element:action (or something like this). One way you could do this is by using this selector: nav > ul > li:hover then apply the style you want with the cursor property pointer, like cursor: pointer;
I hope I was of some assistance! God bless you!
Edit: you have to use the nav > ul > li:hover because you may have other li elements and you want to style a specific one.
So I re-wrote it like this …
cusor: pointer;
color: #1b1b32;
background-color: #dfdfe2;
}```
Still getting this error message. You should give hovered li elements a background-color of #dfdfe2 which I think that I did...?
not sure where I went wrong...
li > a {
color: inherit;
text-decoration: none;
background-color: #dfdfe2;
}
nav > ul > li:hover {
color: #1b1b32;
cursor: pointer;
}```
This is what I have now. I'm still getting the same error message.
Got it. Thank you…had too many edits going . Started over and followed your post and the hints…
Thank you !