边框构图

<!DOCTYPE html>
<html lang="en">
<head>
   <meta charset="UTF-8">
   <title>Document</title>
   <style type="text/css">
*{
   margin: 0;
   padding: 0;
}
div
{
   margin:200px auto;
   width: 800px;
   height: 500px;
   background-color: pink;
}
ul
{
   list-style: none;
}
li
{
   width: 200px;
   height: 200px;
   border:1px solid;
   float: left;
   margin-top: 10px;
   margin-left:50px;
   margin-bottom: 50px;
}
li>.div1
{
     margin:30px auto;
     width: 100px;
     height: 100px;
     border:1px solid;
}
li:nth-of-type(1)>.div1
{
   border-radius: 50%;
}
li:nth-of-type(2)>.div1
{
   width: 30px;
   height: 30px;
   border:50px solid red;
   border-radius: 0px 50px 26px 50px /0px 50px 52px 50px ;
}
li:nth-of-type(3)>.div1
{
   width: 0px;
   height: 0px;
    border-left: 50px solid red;
    border-right: 50px solid black;
    border-top:50px solid yellow;
    border-bottom:50px solid blue;
}
li:nth-of-type(4)>.div1
{
   border-radius: 50px;
   background-color: red;
   border:none;
}
li:nth-of-type(5)>.div1
{
   width: 120px;
   height: 0px;
   border-top: 60px solid white;
   border-bottom: 60px solid black;
   border-radius: 100%;

}
li:nth-of-type(5)>.div1::before
{
   content: "";
   display: block;
   width: 20px;
   height: 20px;
   border:20px solid white;
   border-radius: 100%;
   background-color: black;
    margin-left: 60px;
    margin-top: -30px;
}
li:nth-of-type(5)>.div1::after
{
   content: "";
   display: block;
   width: 20px;
   height: 20px;
   border:20px solid black;
   border-radius: 100%;
   background-color: white;
    margin-left: 0px;
    margin-top: -60px;
}
li:nth-of-type(6)>.div1
{
    width: 100px;
    height: 50px;
    background-color: red;
    margin:50px auto;
    border-radius: 10px;
    
    border:none;
}
li:nth-of-type(6)>.div1::before
{
   content: "";
   display: block;
   width: 20px;
   height: 30px;
   background-color: red;
   border-radius: 0 0 30px 0/ 0 0 60px 0;
   position: relative;
   top: 8px;
   left: 94px;
}
li:nth-of-type(6)>.div1::after
{
   content: "";
   display: block;
   width: 20px;
   height: 20px;
   border-radius: 0 0 30px 0;
   background-color: pink;
   position: relative;
   top: -22px;
   left: 100px;
}
</style>
</head>
<body>
   <div>
        <ul>
        <li><div class="div1"></div></li>
        <li><div class="div1"></div></li>
        <li><div class="div1"></div></li>
        <li><div class="div1"></div></li>
        <li><div class="div1"></div></li>
        <li><div class="div1"></div></li>
        </ul>
     </div> 
   
</body>
</html>

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值