mirror of
https://github.com/twbs/bootstrap.git
synced 2025-02-26 23:54:23 +01:00
Add Split button Dropdown Center menu example
This commit is contained in:
parent
92aedd15fc
commit
e0bb4ffd0e
@ -408,7 +408,8 @@ And putting it to use in a navbar:
|
|||||||
Make the dropdown menu centered below the toggle with `.dropdown-center` on the parent element.
|
Make the dropdown menu centered below the toggle with `.dropdown-center` on the parent element.
|
||||||
|
|
||||||
{{< example >}}
|
{{< example >}}
|
||||||
<div class="dropdown-center">
|
<div class="d-inline-grid d-md-inline-flex gap-4">
|
||||||
|
<div class="dropdown-center">
|
||||||
<button class="btn btn-secondary dropdown-toggle" type="button" data-bs-toggle="dropdown" aria-expanded="false">
|
<button class="btn btn-secondary dropdown-toggle" type="button" data-bs-toggle="dropdown" aria-expanded="false">
|
||||||
Centered dropdown
|
Centered dropdown
|
||||||
</button>
|
</button>
|
||||||
@ -417,6 +418,21 @@ Make the dropdown menu centered below the toggle with `.dropdown-center` on the
|
|||||||
<li><a class="dropdown-item" href="#">Action two</a></li>
|
<li><a class="dropdown-item" href="#">Action two</a></li>
|
||||||
<li><a class="dropdown-item" href="#">Action three</a></li>
|
<li><a class="dropdown-item" href="#">Action three</a></li>
|
||||||
</ul>
|
</ul>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="btn-group dropdown-center">
|
||||||
|
<button class="btn btn-secondary" type="button">
|
||||||
|
Centered dropdown
|
||||||
|
</button>
|
||||||
|
<button type="button" class="btn btn-secondary dropdown-toggle dropdown-toggle-split" data-bs-toggle="dropdown" aria-expanded="false">
|
||||||
|
<span class="visually-hidden">Toggle Dropdown</span>
|
||||||
|
</button>
|
||||||
|
<ul class="dropdown-menu">
|
||||||
|
<li><a class="dropdown-item" href="#">Action</a></li>
|
||||||
|
<li><a class="dropdown-item" href="#">Action two</a></li>
|
||||||
|
<li><a class="dropdown-item" href="#">Action three</a></li>
|
||||||
|
</ul>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
{{< /example >}}
|
{{< /example >}}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user