Ciel
Ciel

Reputation: 4440

Twitter Bootstrap - Full-Height Highlight on navbar active links

I am trying to use bootstrap for a project, and am hitting a problem where I am trying to change the background color of a link marked as active in the navbar. For reasons I can't seem to track down, there is always a border beneath it that I just can't trim away or get rid of.

I'm not trying to do anything particularly crazy, am I?

CSS

.navbar-default .navbar-nav>.active>a { background-color: #000; }

Example

Upvotes: 0

Views: 116

Answers (1)

Bryan Willis
Bryan Willis

Reputation: 3642

Navbar Default adds a border to the entire menu:

.navbar-default {
    border-color: #e7e7e7; 
}

To remove it:

.navbar-default {
    border: none; 
}

or the default .navbar border is transparent, which will also work:

.navbar-default {
    border: 1px solid transparent; 
}

Upvotes: 1

Related Questions