I have an <li> that on hover shows a <ul> beneath it. I finally got the borders aligned but now for some reason the li:hover color won’t change back when I hover off of it. What seems to be happening is that when the <ul> is active the parent <li> remains hovered according to CSS.
Here’s a jsFiddle showing what’s going on:
When the <ul> is showing and the parent <li> isn’t being hovered over, I’d like the parent <li> to have the same background color and border color of the <li> elements within the <ul>. How can I best fix this while maintaining the border integrity of the entire <div>?
You could by changing
to
Also you could then put:
To keep it looking consistent. http://jsfiddle.net/Luryf/4/
update: whoops. Seems also needed to move the
border-*andborder-radius-*into its own. (fromparenttoparent a) http://jsfiddle.net/Luryf/8/from:
to: