]> git.ipfire.org Git - ipfire.org.git/blob - src/scss/bootstrap-4.0.0-alpha.6/docs/utilities/vertical-align.md
Introduce autotools
[ipfire.org.git] / src / scss / bootstrap-4.0.0-alpha.6 / docs / utilities / vertical-align.md
1 ---
2 layout: docs
3 title: Vertical alignment
4 group: utilities
5 ---
6
7 Change the alignment of elements with the [`vertical-alignment`](https://developer.mozilla.org/en-US/docs/Web/CSS/vertical-align) utilities. Please note that vertical-align only affects inline, inline-block, inline-table, and table cell elements.
8
9 Choose from `.align-baseline`, `.align-top`, `.align-middle`, `.align-bottom`, `.align-text-bottom`, and `.align-text-top` as needed.
10
11 With inline elements:
12
13 {% example html %}
14 <span class="align-baseline">baseline</span>
15 <span class="align-top">top</span>
16 <span class="align-middle">middle</span>
17 <span class="align-bottom">bottom</span>
18 <span class="align-text-top">text-top</span>
19 <span class="align-text-bottom">text-bottom</span>
20 {% endexample %}
21
22 With table cells:
23
24 {% example html %}
25 <table style="height: 100px;">
26 <tbody>
27 <tr>
28 <td class="align-baseline">baseline</td>
29 <td class="align-top">top</td>
30 <td class="align-middle">middle</td>
31 <td class="align-bottom">bottom</td>
32 <td class="align-text-top">text-top</td>
33 <td class="align-text-bottom">text-bottom</td>
34 </tr>
35 </tbody>
36 </table>
37 {% endexample %}