CSS让图片垂直居中

2020/03/25 by Jinyang | Filed under 技术相关.
<div style="display:table-cell;line-height:30px;text-align:left;vertical-align:middle;font-weight:bold;color:black;">

<img style="display: inline-block;"
src="redbar.png"
height="14px"
/>
<span>文字文字文字</span>

</div>

Leave a Reply

Your email address will not be published. Required fields are marked *

返回顶部