MaTTo
MaTTo

Reputation: 2396

Twitter Bootstrap dropdown submenu background color

I'm having a little trouble with background color of my dropdown menu. I changed the color of background color on hover to orange. But, if I go to any submenu in that dropdown, the color of parent item change to default blue. Don't know, how to explain it better, I will just show a picture:

TWB Submenu

So, as soon as I hover over subitem, the parent background color change to blue. I was trying to do a selector for that but ran out of ideas. Any help please?

Upvotes: 1

Views: 4241

Answers (1)

Carol Skelly
Carol Skelly

Reputation: 362790

I think you need something like this to ensure all CSS selectors are covered...

/* change background color on hover */
.dropdown-submenu > a:focus, .dropdown-submenu > a:hover, .dropdown-submenu:focus>a, r, .dropdown-submenu:hover>a,
.dropdown-menu > li a:hover,
.dropdown-menu > li a:focus { background-color: orange; background-image: none; filter: none; text-decoration: none; border: none; }

Demo: http://bootply.com/75155

Upvotes: 4

Related Questions