骨架
html
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Document</title>
<link rel="stylesheet" href="./小米.css">
</head>
<body>
<div class="father">
<div class="left"></div>
<div class="right">
<ul>
<li></li>
<li></li>
<li></li>
<li></li>
<li></li>
<li></li>
<li></li>
<li></li>
</ul>
</div>
</div>
</body>
</html>
css
html
* {
padding: 0;
margin: 0;
box-sizing: border-box;
}
.father{
width: 1240px;
height: 628px;
background-color: blue;
margin: 0 auto;
display: flex;
justify-content: space-between;
flex-flow:row;
}
.left{
width: 247px;
height: 614px;
background-color: pink;
}
.right{
width: 978px;
height: 628px;
background-color: aqua;
border: 0px;
display: flex;
}
.ul{
width: 992px;
height: 614px;
padding-left: 14px;
display: flex;
justify-content: space-between;
}
li {
list-style: none;
}
.father li {
width: 234px;
height: 300px;
background-color:red ;
margin: 0px 9px 9px 0px;
display: inline-block;
}
.father li:nth-child(4n){
margin-right: 0;
}
效果