markdownify button dropdowns

This commit is contained in:
Mark Otto 2014-07-13 01:23:29 -07:00
parent 35d87bcb25
commit 4a5f1f036b
1 changed files with 240 additions and 232 deletions

View File

@ -3,18 +3,17 @@ layout: page
title: Button dropdown
---
<div class="bs-docs-section">
<h1 id="btn-dropdowns" class="page-header">Button dropdowns</h1>
<p class="lead">Use any button to trigger a dropdown menu by placing it within a <code>.btn-group</code> and providing the proper menu markup.</p>
Use any button to trigger a dropdown menu by placing it within a `.btn-group` and providing the proper menu markup.
<div class="bs-callout bs-callout-danger">
<h4>Plugin dependency</h4>
<p>Button dropdowns require the <a href="../javascript/#dropdowns">dropdown plugin</a> to be included in your version of Bootstrap.</p>
</div>
<h3 id="btn-dropdowns-single">Single button dropdowns</h3>
<p>Turn a button into a dropdown toggle with some basic markup changes.</p>
### Single button dropdowns
Turn a button into a dropdown toggle with some basic markup changes.
<div class="bs-example">
<div class="btn-group">
<button type="button" class="btn btn-secondary dropdown-toggle" data-toggle="dropdown">Default</button>
@ -77,6 +76,7 @@ title: Button dropdown
</ul>
</div><!-- /btn-group -->
</div>
{% highlight html %}
<!-- Single button -->
<div class="btn-group">
@ -93,8 +93,10 @@ title: Button dropdown
</div>
{% endhighlight %}
<h3 id="btn-dropdowns-split">Split button dropdowns</h3>
<p>Similarly, create split button dropdowns with the same markup changes, only with a separate button.</p>
### Split button dropdowns
<Similarly, create split button dropdowns with the same markup changes, only with a separate button.
<div class="bs-example">
<div class="btn-group">
<button type="button" class="btn btn-secondary">Default</button>
@ -175,6 +177,7 @@ title: Button dropdown
</ul>
</div><!-- /btn-group -->
</div>
{% highlight html %}
<!-- Split button -->
<div class="btn-group">
@ -192,8 +195,10 @@ title: Button dropdown
</div>
{% endhighlight %}
<h3 id="btn-dropdowns-sizing">Sizing</h3>
<p>Button dropdowns work with buttons of all sizes.</p>
### Sizing
Button dropdowns work with buttons of all sizes.
<div class="bs-example">
<div class="btn-toolbar" role="toolbar">
<div class="btn-group">
@ -238,6 +243,7 @@ title: Button dropdown
</div><!-- /btn-group -->
</div><!-- /btn-toolbar -->
</div><!-- /example -->
{% highlight html %}
<!-- Large button group -->
<div class="btn-group">
@ -270,8 +276,10 @@ title: Button dropdown
</div>
{% endhighlight %}
<h3 id="btn-dropdowns-dropup">Dropup variation</h3>
<p>Trigger dropdown menus above elements by adding <code>.dropup</code> to the parent.</p>
### Dropup variation
Trigger dropdown menus above elements by adding `.dropup` to the parent.
<div class="bs-example">
<div class="btn-toolbar" role="toolbar">
<div class="btn-group dropup">
@ -301,7 +309,8 @@ title: Button dropdown
</ul>
</div><!-- /btn-group -->
</div>
</div><!-- /example -->
</div>
{% highlight html %}
<div class="btn-group dropup">
<button type="button" class="btn btn-secondary">Dropup</button>
@ -313,4 +322,3 @@ title: Button dropdown
</ul>
</div>
{% endhighlight %}
</div>