我们可以利用css3来实现这个小三角

// css3
.tag{
    width:300px;
  height:100px;
  border:1px solid #eee;
  position:relative;
  background-color:#FFF;
    top: 50px;
}
.tag:before,.tag:after{
    content: '';
    display: block;
    position: absolute;
    border-width: 10px;
    top: -20px;
    left: 160px;
    border-style: dashed dashed solid;
    border-color: transparent transparent #eee;
    font-size: 0;
    line-height: 0;
}
.tag:after{
    top: -19px;
    border-color: transparent transparent #fff;
}

// html

<div class="tag">
    css3气泡框
</div>

  转载自纯CSS气泡框实现方法探究

 

猜你喜欢

转载自www.cnblogs.com/ron123/p/9152266.html
今日推荐