2
0
mirror of https://github.com/tenrok/bootstrap.git synced 2026-06-08 17:22:31 +03:00

add justified nav links for tabs and pills

This commit is contained in:
Mark Otto
2012-11-04 00:52:10 -07:00
parent 05a2d37559
commit 83a3789b5e
4 changed files with 129 additions and 52 deletions
+45 -29
View File
@@ -85,6 +85,51 @@
// Pills
// -------------------------
// Links rendered as pills
.nav-pills > li > a {
border-radius: 5px;
}
.nav-pills > li + li > a {
margin-left: 2px;
}
// Active state
.nav-pills > .active > a,
.nav-pills > .active > a:hover {
color: @white;
background-color: @linkColor;
}
// Stacked pills
.nav-stacked > li {
float: none;
}
.nav-stacked > li + li > a {
margin-top: 2px;
margin-left: 0; // no need for the gap between nav items
}
// Justified navs
// -------------------------
.nav-justified {
// Negative margin doesn't work, so we hack it
max-height: 37px;
}
.nav-justified > li {
float: none;
display: table-cell;
width: 1%;
text-align: center;
}
// Lists
// -------------------------
@@ -123,35 +168,6 @@
// Pills
// -------------------------
// Links rendered as pills
.nav-pills > li > a {
border-radius: 5px;
}
.nav-pills > li + li > a {
margin-left: 2px;
}
// Active state
.nav-pills > .active > a,
.nav-pills > .active > a:hover {
color: @white;
background-color: @linkColor;
}
// Stacked pills
.nav-stacked > li {
float: none;
}
.nav-stacked > li + li > a {
margin-top: 2px;
margin-left: 0; // no need for the gap between nav items
}
// Dropdowns
// -------------------------