[css3]flex弹性布局

div class="box"
  div class="item"/div
/div



.box{
  background-color:orange;
  width:150px;
  height:200px;
  border-radius:15px;
  display:flex;
  box-shadow:0 0 5px #000;
  justify-content:center;
  flex-wrap:wrap;
  align-content:center;
  flex-direction:row;
  align-items:center;
}
.item{
  background-color:#000;
  width:20px;
  height:20px;
  border-radius:15px;
}  

实现水平垂直居中

转载于:https://www.cnblogs.com/positive/p/5082838.html

最新回复(0)
/jishuqqxV6hRT7Wap1L9wC2Fn_2FgQ6GPdp4O1qgr81zbgkARY_3D
8