mirror of
https://github.com/twbs/bootstrap.git
synced 2024-12-01 13:24:25 +01:00
Merge pull request #9521 from Luis-TP/fix-javascript-docs
Javascript Docs: Add .navbar-header, and correct .nav-collapse
This commit is contained in:
commit
057a87ed65
@ -356,15 +356,16 @@ $('#myModal').on('hidden.bs.modal', function () {
|
||||
<h3>Within a navbar</h3>
|
||||
<div class="bs-example">
|
||||
<nav id="navbar-example" class="navbar navbar-static" role="navigation">
|
||||
<div class="container" style="width: auto;">
|
||||
<a class="navbar-brand" href="#">Project Name</a>
|
||||
<div class="navbar-header">
|
||||
<button class="navbar-toggle" type="button" data-toggle="collapse" data-target=".bs-js-navbar-collapse">
|
||||
<span class="sr-only">Toggle navigation</span>
|
||||
<span class="icon-bar"></span>
|
||||
<span class="icon-bar"></span>
|
||||
<span class="icon-bar"></span>
|
||||
</button>
|
||||
<div class="nav-collapse collapse bs-js-navbar-collapse">
|
||||
<a class="navbar-brand" href="#">Project Name</a>
|
||||
</div>
|
||||
<div class="navbar-collapse collapse bs-js-navbar-collapse">
|
||||
<ul class="nav navbar-nav">
|
||||
<li class="dropdown">
|
||||
<a id="drop1" href="#" role="button" class="dropdown-toggle" data-toggle="dropdown">Dropdown <b class="caret"></b></a>
|
||||
@ -400,7 +401,6 @@ $('#myModal').on('hidden.bs.modal', function () {
|
||||
</li>
|
||||
</ul>
|
||||
</div><!-- /.nav-collapse -->
|
||||
</div><!-- /.container -->
|
||||
</nav> <!-- /navbar-example -->
|
||||
</div> <!-- /example -->
|
||||
|
||||
@ -527,8 +527,9 @@ $('#myDropdown').on('show.bs.dropdown', function () {
|
||||
<p>The ScrollSpy plugin is for automatically updating nav targets based on scroll position. Scroll the area below the navbar and watch the active class change. The dropdown sub items will be highlighted as well.</p>
|
||||
<div class="bs-example">
|
||||
<nav id="navbar-example2" class="navbar navbar-static" role="navigation">
|
||||
<div class="container" style="width: auto;">
|
||||
<div class="navbar-header">
|
||||
<a class="navbar-brand" href="#">Project Name</a>
|
||||
</div>
|
||||
<ul class="nav navbar-nav">
|
||||
<li><a href="#fat">@fat</a></li>
|
||||
<li><a href="#mdo">@mdo</a></li>
|
||||
@ -542,7 +543,6 @@ $('#myDropdown').on('show.bs.dropdown', function () {
|
||||
</ul>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
</nav>
|
||||
<div data-spy="scroll" data-target="#navbar-example2" data-offset="0" class="scrollspy-example">
|
||||
<h4 id="fat">@fat</h4>
|
||||
|
Loading…
Reference in New Issue
Block a user