0
0
mirror of https://github.com/twbs/bootstrap.git synced 2025-01-28 20:52:21 +01:00

Address #6459 and add mention of disabled links in dropdowns to le docs

This commit is contained in:
Mark Otto 2013-01-12 00:33:12 -08:00
parent 8a16746542
commit a7231854c9
2 changed files with 38 additions and 0 deletions

View File

@ -161,6 +161,25 @@
<ul class="dropdown-menu pull-right" role="menu" aria-labelledby="dLabel">
...
</ul>
</pre>
<h3>Disabled menu options</h3>
<p>Add <code>.disabled</code> to a <code>&lt;li&gt;</code> in the dropdown to disable the link.</p>
<div class="bs-docs-example">
<div class="dropdown clearfix">
<ul class="dropdown-menu" role="menu" aria-labelledby="dropdownMenu" style="display: block; position: static; margin-bottom: 5px; *width: 180px;">
<li><a tabindex="-1" href="#">Regular link</a></li>
<li class="disabled"><a tabindex="-1" href="#">Disabled link</a></li>
<li><a tabindex="-1" href="#">Another link</a></li>
</ul>
</div>
</div>
<pre class="prettyprint linenums">
&lt;ul class="dropdown-menu" role="menu" aria-labelledby="dropdownMenu"&gt;
&lt;li&gt;&lt;a tabindex="-1" href="#"&gt;Regular link&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a tabindex="-1" href="#"&gt;Disabled link&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a tabindex="-1" href="#"&gt;Another link&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
</pre>
<h3>Sub menus on dropdowns</h3>

View File

@ -90,6 +90,25 @@
&lt;ul class="dropdown-menu pull-right" role="menu" aria-labelledby="dLabel"&gt;
...
&lt;/ul&gt;
</pre>
<h3>{{_i}}Disabled menu options{{/i}}</h3>
<p>{{_i}}Add <code>.disabled</code> to a <code>&lt;li&gt;</code> in the dropdown to disable the link.{{/i}}</p>
<div class="bs-docs-example">
<div class="dropdown clearfix">
<ul class="dropdown-menu" role="menu" aria-labelledby="dropdownMenu" style="display: block; position: static; margin-bottom: 5px; *width: 180px;">
<li><a tabindex="-1" href="#">{{_i}}Regular link{{/i}}</a></li>
<li class="disabled"><a tabindex="-1" href="#">{{_i}}Disabled link{{/i}}</a></li>
<li><a tabindex="-1" href="#">{{_i}}Another link{{/i}}</a></li>
</ul>
</div>
</div>{{! /example }}
<pre class="prettyprint linenums">
&lt;ul class="dropdown-menu" role="menu" aria-labelledby="dropdownMenu"&gt;
&lt;li&gt;&lt;a tabindex="-1" href="#"&gt;{{_i}}Regular link{{/i}}&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a tabindex="-1" href="#"&gt;{{_i}}Disabled link{{/i}}&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a tabindex="-1" href="#"&gt;{{_i}}Another link{{/i}}&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
</pre>
<h3>{{_i}}Sub menus on dropdowns{{/i}}</h3>