mirror of
https://github.com/twbs/bootstrap.git
synced 2025-08-30 08:39:56 +02:00
v4: Flexbox nav options (#21201)
* Add some flexbox nav components - Includes .nav-justified for inline, tab, and pill nav components - Includes example of using the flex utils (.d- and .flex-items-) for centered nav * redo heading hierarchy a bit
This commit is contained in:
@@ -155,3 +155,25 @@
|
||||
display: block;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
// Justified navigation (flexbox only)
|
||||
//
|
||||
// Justified nav components are only built for flexbox mode in Bootstrap 4. In
|
||||
// previous versions, this component variation was limited to anchor-based nav
|
||||
// implementations--meaning it couldn't be used on button elements. This is due
|
||||
// to a longstanding Safari bug in responsive table styles.
|
||||
//
|
||||
// Using flexbox, we avoid that problem altogether at the cost of no default
|
||||
// justified navigation for default Bootstrap. Sorry, y'all <3.
|
||||
|
||||
@if $enable-flex {
|
||||
.nav-justified {
|
||||
display: flex;
|
||||
|
||||
.nav-item {
|
||||
flex: 1;
|
||||
text-align: center;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user