<div id="clipped2">
做工
</div>
#clipped2 {
position: relative;
display: inline-block;
align-items: center;
justify-content: center;
min-width: 80px;
box-size: content-box;
height: 26px;
font-size: 12px;
background: #fff;
border-radius: 2px;
border: 1px solid red;
clip-path: polygon(20px 0, 100% 0, 100% 100%, 0 100%, 0 14px);
/* padding: 0 20px; */
padding 1.2em;
text-align: center;
}
#clipped2:before {
position: absolute;
left: -2px;
top: 6px;
transform: rotate(-35deg);
content: '';
width: 25px;
height: 1px;
background: red;
}
三角形 clip-path :before
猜你喜欢
转载自blog.csdn.net/mrzhangdulin/article/details/84297060
今日推荐
周排行