我正在使用Bootstrap 4-beta2' ml-auto
来实现选项卡式界面。
如何将某些元素对齐到屏幕右侧?
在最后li
项目上设置ul
不起作用。拆分两个ul
中的tabright
不起作用,因为它允许tableft1
与<nav class="fixed-top bg-dark">
<div class="navbar">
<a class="navbar-brand" href="#tabmain">Brand</a>
<ul class="nav nav-pills mr-auto">
<li class="nav-pill active"><a class="nav-link" href="#tableft1" data-toggle="pill">TabLeft1</a></li>
<li class="nav-pill"><a class="nav-link" href="#tableft2" data-toggle="pill">TabLeft2</a></li>
<li class="nav-pill"><a class="nav-link" href="#tabright" data-toggle="pill">TabRight</a></li>
</ul>
</div>
</nav>
同时处于活动状态。< / p>
const char* cp;
char p = 'U';
cp = &p;
答案 0 :(得分:0)
原来navbar
是flex,因此特定于flex的类正在帮助:
<nav class="fixed-top bg-dark">
<div class="navbar justify-content-start flex-nowrap">
<a class="navbar-brand" href="#tabmain">Brand</a>
<ul class="nav nav-pills w-100">
<li class="nav-pill active"><a class="nav-link" href="#tableft1" data-toggle="pill">TabLeft1</a></li>
<li class="nav-pill"><a class="nav-link" href="#tableft2" data-toggle="pill">TabLeft2</a></li>
<li class="nav-pill ml-auto"><a class="nav-link" href="#tabright" data-toggle="pill">TabRight</a></li>
</ul>
</div>
</nav>