Bootstrap 4参考手册
实用工具 | Utilities
垂直对齐 | Vertical alignment
轻松更改内联,内联块,内嵌表格和表格单元格元素的垂直对齐方式。
用vertical-alignment
实用程序更改元素的对齐方式。请注意,垂直对齐仅影响内联,内联块,内联表和表格单元格元素。
选择.align-baseline
,.align-top
,.align-middle
,.align-bottom
,.align-text-bottom
,和.align-text-top
。
内联元素:
打开getbootstrap.com上的示例
<span class="align-baseline">baseline</span>
<span class="align-top">top</span>
<span class="align-middle">middle</span>
<span class="align-bottom">bottom</span>
<span class="align-text-top">text-top</span>
<span class="align-text-bottom">text-bottom</span>
使用表格单元格:
打开getbootstrap.com上的示例
<table style="height: 100px;">
<tbody>
<tr>
<td class="align-baseline">baseline</td>
<td class="align-top">top</td>
<td class="align-middle">middle</td>
<td class="align-bottom">bottom</td>
<td class="align-text-top">text-top</td>
<td class="align-text-bottom">text-bottom</td>
</tr>
</tbody>
</table>
实用工具 | Utilities相关
Bootstrap 是一套用于 HTML、CSS 和 JS 开发的开源工具集。利用我们提供的 Sass 变量和大量 mixin、响应式栅格系统、可扩展的预制组件、基于 jQuery 的强大的插件系统,能够快速为你的想法开发出原型或者构建整个 app 。
主页 | https://getbootstrap.com/ |
源码 | https://github.com/twbs/bootstrap |
版本 | 4 |
发布版本 | 4.0.0-beta.2 |