我有一个Bootstrap下拉列表。页面加载后,菜单将展开。我怎样才能解决这个问题?
这是截图和代码:
<div class="col-lg-3">
<div class="bs-component">
<ul class="nav nav-pills nav-stacked">
<li class="dropdown open">
<a id="ModelFilter" class="dropdown-toggle" data-toggle="dropdown" href="#" aria-expanded="true">
Dropdown <span class="caret"></span>
</a>
<ul class="dropdown-menu">
<li><a href="#">Action</a></li>
<li><a href="#">Another action</a></li>
<li><a href="#">Something else here</a></li>
<li class="divider"></li>
<li><a href="#">Separated link</a></li>
</ul>
</li>
</ul>
</div>
</div>
答案 0 :(得分:4)
从open
元素
<li>
<li class="dropdown"> ... </li>