0

I have searched and searched and cannot figure out how to reduce my Bootstrap menu's drop-down size. I have tried modifying everything related to drop-downs in the Bootstrap CSS and cannot get it change.

My current Bootstrap dropdown:

enter image description here

I would like to make the space between each item smaller. Here is my current custom nav CSS:

.navbar-brand,
.navbar-nav li a {
    line-height: 100px;
    height: 100px;
    padding-top: 0;
}
WebDevBooster
  • 14,674
  • 9
  • 66
  • 70

2 Answers2

1

Figured it out. Had to add this to my css code:

.navbar-brand,
.navbar-nav li a {
    line-height: 100px;
    height: 100px;
    padding-top: 0;
}

.dropdown-menu li a {
    line-height: 100px;
    height: 100px;
    padding-top: 0;
}
0

Remove line-height and height property

.navbar-brand,
.navbar-nav li a {

    max-height: auto;
    padding-top: 0;
}

Update 1 :

.navbar-brand,
.navbar-nav > li> a {
    line-height: 100px;
    height: 100px;
    padding-top: 0;
}

Use > to apply styles under the root class.

LIVE DEMO

Aravind
  • 40,391
  • 16
  • 91
  • 110