I am trying to narrow the height of my navbar so that it does not expand (in height) for certain screen sizes or when extra text is added to the navbar.
This is my html:
<div class="navbar navbar-inverse navbar-fixed-top" id="navbar-site">
<div class="container">
<div class="navbar-header">
<button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-collapse">
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
@Html.ActionLink("Website Name", "Index", "Home", new { area = "" }, new { @class = "navbar-brand" })
</div>
<div class="navbar-collapse collapse navbar-options">
<ul class="nav navbar-nav">
<li>@Html.ActionLink("Home", "Index", "Home")</li>
<li>@Html.ActionLink("About", "About", "Home")</li>
<li>@Html.ActionLink("Link", "Link", "Link")</li>
<li>@Html.ActionLink("Link", "Link", "Link")</li>
<li>@Html.ActionLink("Link", "Link", "Link")</li>
<li>@Html.ActionLink("Link", "Link", "Link")</li>
</ul>
@Html.Partial("_LoginPartial")
</div>
</div>
</div>
My CSS:
#navbar-site {
height: 15px;
}
I have tried adding a height and max height css to my navbar but still no luck.
Update: here is a running version of my problem on bootply. Note what happens when the window is made smaller, the height is expanded and the links nestle beneath.