请问怎么让我这里的文本垂直居中?
Html:
Html:
<script src="//at.alicdn.com/t/font_wucl02m681zia4i.js" type="text/javascript"></script>
<div id="postMeta">
<!-- 博文分类 -->
<a rel="nofollow noopener" href="https://www.cnblogs.com/iMath/category/1107555.html" id="catogory">
<svg class="icon" aria-hidden="true">
<use xlink:href="#icon-fenlei2"></use>
</svg>
</a>
<!-- 阅读统计 -->
<div id="postViewCount">
<svg class="icon" aria-hidden="true">
<use xlink:href="#icon-yuedu1"></use>
</svg>
<span class="post_view_count">5531</span>
</div>
<!-- 发布日期 -->
<div>
<svg class="icon" aria-hidden="true">
<use xlink:href="#icon-history"></use>
</svg>
<span class="post-date">2018-06-25</span>
</div>
<!-- 编辑 -->
<a rel="nofollow noopener" href="https://i.cnblogs.com/EditPosts.aspx?postid=9223247">
<svg class="icon" aria-hidden="true" id="icon-bianji">
<use xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="#icon-bianji4"></use>
</svg>
</a>
</div>
CSS:
#postMeta{
display: flex;
justify-content: space-around;
align-items: center;
/* height:100px; */
}
<script src="//at.alicdn.com/t/font_wucl02m681zia4i.js" type="text/javascript"></script>
<div id="postMeta">
<!-- 博文分类 -->
<a rel="nofollow noopener" class="align-center" href="https://www.cnblogs.com/iMath/category/1107555.html" id="catogory">
<svg class="icon" aria-hidden="true">
<use xlink:href="#icon-fenlei2"></use>
</svg>
</a>
<!-- 阅读统计 -->
<div id="postViewCount" class="align-center">
<svg class="icon" aria-hidden="true">
<use xlink:href="#icon-yuedu1"></use>
</svg>
<span class="post_view_count">5531</span>
</div>
<!-- 发布日期 -->
<div class="align-center">
<svg class="icon" aria-hidden="true">
<use xlink:href="#icon-history"></use>
</svg>
<span class="post-date">2018-06-25</span>
</div>
<!-- 编辑 -->
<a rel="nofollow noopener" class="align-center" href="https://i.cnblogs.com/EditPosts.aspx?postid=9223247">
<svg class="icon" aria-hidden="true" id="icon-bianji">
<use xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="#icon-bianji4"></use>
</svg>
</a>
</div>
<style>
display: flex;
justify-content: space-around;
align-items: center;
/* height:100px; */
}
#postMeta .align-center{
display: flex;
justify-content: space-around;
align-items: center;
}
</style>
多谢!在你的启示下我主要用了·svg {
vertical-align: middle;
}·解决了!