I'm utilizing Bootstrap 4 along with this CSS class to vertically align my elements:
.vertical-align {
display: flex;
flex-direction: row;
}
.vertical-align > [class^="col-"],
.vertical-align > [class*=" col-"] {
display: flex;
align-items: center;
justify-content: flex-start;
}
However, everything is currently aligned to the left. How can I align, for instance, the list (ul> li) to the right? All my attempts have been unsuccessful so far.
Below is a demonstration that works:
.vertical-align {
display: flex;
flex-direction: row;
}
.vertical-align > [class^="col-"],
.vertical-align > [class*=" col-"] {
display: flex;
align-items: center;
justify-content: flex-start;
}
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0-alpha.2/js/bootstrap.min.js"></script>
<link href="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0-alpha.2/css/bootstrap.min.css" rel="stylesheet"/>
<div class="container-fluid">
<div class="row vertical-align">
<div class="col-md-3" style="background-color: #f1f1f1;">
<div class="logo">
<img src="http://placehold.it/120x50" alt="" class="img-responsive">
</div>
</div>
<div class="col-md-6" style="background-color: #ffccff;">
<div class="categories">
<ul class="list-inline top_categories">
<li class="list-inline-item">
<a href="#">Category 1</a>
</li>
<li class="list-inline-item">
<a href="#">Category 2</a>
</li>
<li class="list-inline-item">
<a href="#">Category 3</a>
</li>
<li class="list-inline-item">
<a href="#">Category 4</a>
</li>
</ul>
</div>
</div>
<div class="col-md-3" style="background-color: #f1f1f1;">
SEARCH
</div>
</div>
</div>
A JSFiddle link showing my progress: https://jsfiddle.net/xcottg08/