I am attempting to center font awesome icons within a button so that they align perfectly with the text on a toolbar. Below is the code snippet I am working with:
<div ng-app="app">
<md-toolbar>
<div class="md-toolbar-tools" md-tall"">
<h2>
<span>Icons</span>
</h2>
<md-button class="md-icon-button">
<md-icon md-font-icon="fa-circle" class="fa"></md-icon>
</md-button>
<md-button class="md-icon-button">
<md-icon md-font-icon="fa-circle" class="fa fa-lg"></md-icon>
</md-button>
</div>
</md-toolbar>
</div>
This results in the following layout:
https://i.sstatic.net/kMvqJ.png
Even though the fa-lg
on the second icon appears centered, it may actually be aligned to the top. I have attempted adding layout-alignment="center center"
to the md-button
, but to no avail.
How can I adjust the alignment of font awesome icons inside md-buttons and more specifically, how can I vertically center them within the toolbar? Is there an Angular Material method for achieving this alignment, or do I need to use custom CSS?