.flex{
display: flex;
flex-direction: row;
flex-wrap: wrap;
border: 1px solid green;
}
.item{
margin-bottom: 5px;
margin-right: 5px;
background: pink;
width: 70px;
height: 50px;
line-height: 50px;
text-align: center;
}
<div class="flex">
<div class="item">
</div>
<div class="item">
</div>
...
</div>
how the width of the parent layer DIV is not left blank after the line wrapping