]> git.ipfire.org Git - thirdparty/bootstrap.git/commitdiff
Drop `.nav-header` for `.dropdown-header`
authorMark Otto <otto@github.com>
Thu, 18 Jul 2013 06:54:09 +0000 (23:54 -0700)
committerMark Otto <otto@github.com>
Thu, 18 Jul 2013 06:54:09 +0000 (23:54 -0700)
* Since we no longer have `.nav-list`, I've nuked the `.nav-header`
* However, dropdowns can still have section headings, so I've kept that
around with the addition of `.dropdown-header`
* Restyled it a smidge as well

docs/_includes/nav-components.html
docs/assets/css/bootstrap.css
docs/components.html
less/dropdowns.less
less/navs.less

index ed00b62fa3ea8d6656e1d281278855f8f92d6c7b..514dcfed3c06f3f197c99a4c77d73755a084d0cf 100644 (file)
@@ -3,6 +3,7 @@
   <ul class="nav">
     <li><a href="#dropdowns-example">Example</a></li>
     <li><a href="#dropdowns-alignment">Alignment options</a></li>
+    <li><a href="#dropdowns-headers">Headers</a></li>
     <li><a href="#dropdowns-disabled">Disabled menu items</a></li>
   </ul>
 </li>
index e625405e236809c937ee6be79e0a26bb977ef89d..23776952191a28b7bac72a4bbb4190d1fd46afd4 100644 (file)
@@ -2275,6 +2275,14 @@ input[type="button"].btn-block {
   outline: 0;
 }
 
+.dropdown-header {
+  display: block;
+  padding: 3px 20px;
+  font-size: 12px;
+  line-height: 1.428571429;
+  color: #999999;
+}
+
 .dropdown-backdrop {
   position: fixed;
   top: 0;
@@ -2303,11 +2311,6 @@ input[type="button"].btn-block {
   margin-bottom: 1px;
 }
 
-.dropdown .dropdown-menu .nav-header {
-  padding-right: 20px;
-  padding-left: 20px;
-}
-
 .list-group {
   padding-left: 0;
   margin-bottom: 20px;
@@ -2710,17 +2713,6 @@ button.close {
   text-align: center;
 }
 
-.nav-header {
-  display: block;
-  padding: 3px 15px;
-  font-size: 11px;
-  font-weight: bold;
-  line-height: 1.428571429;
-  color: #999999;
-  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.5);
-  text-transform: uppercase;
-}
-
 .tabbable:before,
 .tabbable:after {
   display: table;
index 5cc3a1e2809e72e2a9d663d80e87b99663dc912d..9202b133a1f6bbae05bfd3f4dcf317d1da9f4454 100644 (file)
@@ -46,6 +46,31 @@ lead: "Dozens of reusable components built to provide iconography, dropdowns, na
 <ul class="dropdown-menu pull-right" role="menu" aria-labelledby="dLabel">
   ...
 </ul>
+{% endhighlight %}
+
+    <h3 id="dropdowns-headers">Dropdown headers</h3>
+    <p>Add a header to break up label sections of actions in any dropdown menu.</p>
+    <div class="bs-example">
+      <div class="dropdown clearfix">
+        <ul class="dropdown-menu" role="menu" aria-labelledby="dropdownMenu">
+          <li class="dropdown-header">Dropdown header</li>
+          <li><a tabindex="-1" href="#">Action</a></li>
+          <li><a tabindex="-1" href="#">Another action</a></li>
+          <li><a tabindex="-1" href="#">Something else here</a></li>
+          <li class="divider"></li>
+          <li class="dropdown-header">Dropdown header</li>
+          <li><a tabindex="-1" href="#">Separated link</a></li>
+        </ul>
+      </div>
+    </div><!-- /example -->
+{% highlight html %}
+<ul class="dropdown-menu" role="menu" aria-labelledby="dropdownMenu">
+  <li class="dropdown-header">Dropdown header</li>
+  ...
+  <li class="divider"></li>
+  <li class="dropdown-header">Dropdown header</li>
+  ...
+</ul>
 {% endhighlight %}
 
     <h3 id="dropdowns-disabled">Disabled menu options</h3>
index 8ae9dbba158859e5d26ce051c683cc1f07f19d95..7e35d42871caee81530a0909413ac9e87186d54c 100644 (file)
   }
 }
 
+// Dropdown section headers
+// ---------------------------
+.dropdown-header {
+  display: block;
+  padding: 3px 20px;
+  font-size: @font-size-small;
+  line-height: @line-height-base;
+  color: @gray-light;
+}
+
+
 
 // Backdrop to catch body clicks on mobile, etc.
 // ---------------------------
     margin-bottom: 1px;
   }
 }
-
-// Tweak nav headers
-// ---------------------------
-// Increase padding from 15px to 20px on sides
-.dropdown .dropdown-menu .nav-header {
-  padding-left: 20px;
-  padding-right: 20px;
-}
index 87780a156fc8bcf8c29bdbdfce643ed3cf8f0cae..9f671643a775787bddd0ad78306f40c8926b60f8 100644 (file)
 
 
 
-// Nav headers (for dropdowns and lists)
-// -------------------------
-
-.nav-header {
-  display: block;
-  padding: 3px 15px;
-  font-size: @font-size-mini;
-  font-weight: bold;
-  line-height: @line-height-base;
-  color: @gray-light;
-  text-shadow: 0 1px 0 rgba(255,255,255,.5);
-  text-transform: uppercase;
-}
-
-
-
 // Tabbable tabs
 // -------------------------