用伪元素的content放置一个勾号,然后设置颜色大小就可以了。
示例:
<span class="icon-success"></span>
.icon-success {
display: inline-flex;
justify-content: center;
align-items: center;
width: 58px;
height: 58px;
background-color: #52b358;
border-radius: 50%;
}
.icon-success::after {
content: '✓';
color: #fff;
font-size: 46px;
font-weight: bold;
}
效果如图: