diff options
| author | Pierre-Denis Vanduynslager <[email protected]> | 2016-10-20 14:25:00 -0400 |
|---|---|---|
| committer | Pierre-Denis Vanduynslager <[email protected]> | 2016-10-20 14:25:00 -0400 |
| commit | 9ee304b973a5675a7a59406fdaeef20870f566ce (patch) | |
| tree | 8820ad86b8cd5899ea1d2c9050881b4ff56c8fee /docs/components/dropdowns.md | |
| parent | 27cf3d675c80029ff2cea1e14903886c00119e37 (diff) | |
| parent | b5890e0608ad2262cde4a38e90afa19f1cb5d852 (diff) | |
| download | bootstrap-9ee304b973a5675a7a59406fdaeef20870f566ce.tar.xz bootstrap-9ee304b973a5675a7a59406fdaeef20870f566ce.zip | |
Merge branch 'twbs/v4-dev' into v4-dev
Diffstat (limited to 'docs/components/dropdowns.md')
| -rw-r--r-- | docs/components/dropdowns.md | 19 |
1 files changed, 3 insertions, 16 deletions
diff --git a/docs/components/dropdowns.md b/docs/components/dropdowns.md index affaadc6e..68c388f21 100644 --- a/docs/components/dropdowns.md +++ b/docs/components/dropdowns.md @@ -1,6 +1,7 @@ --- layout: docs title: Dropdowns +description: Toggle contextual overlays for displaying lists of links and more with the Bootstrap dropdown plugin. group: components --- @@ -36,7 +37,7 @@ And with `<a>` elements: {% example html %} <div class="dropdown open"> - <a class="btn btn-secondary dropdown-toggle" href="http://example.com" id="dropdownMenuLink" data-target="#" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false"> + <a class="btn btn-secondary dropdown-toggle" href="https://example.com" id="dropdownMenuLink" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false"> Dropdown link </a> @@ -361,7 +362,7 @@ Trigger dropdown menus above elements by adding `.dropup` to the parent element. <button type="button" class="btn btn-secondary"> Split dropup </button> - <button type="button" class="btn btn-secondary dropdown-toggle" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false"> + <button type="button" class="btn btn-secondary dropdown-toggle dropdown-toggle-split" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false"> <span class="sr-only">Toggle Dropdown</span> </button> <div class="dropdown-menu"> @@ -500,20 +501,6 @@ Add `data-toggle="dropdown"` to a link or button to toggle a dropdown. </div> {% endhighlight %} -To keep URLs intact with link buttons, use the `data-target` attribute instead of `href="#"`. - -{% highlight html %} -<div class="dropdown"> - <a id="dLabel" data-target="#" href="http://example.com" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false"> - Dropdown trigger - </a> - - <div class="dropdown-menu" aria-labelledby="dLabel"> - ... - </div> -</div> -{% endhighlight %} - ### Via JavaScript Call the dropdowns via JavaScript: |
