Skip welcome & menu and move to editor
Welcome to JS Bin
Load cached copy from
 
<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <title>多栏布局</title>
  <style media="screen">
    .wrap{
      display: flex;
      background:#eee;
      text-align: center;
      width:300px;
      margin:0 auto;
      align-items:baseline;
      height:200px;
    }
    .wrap div{
      width:50px;
      margin-right:20px;
    }
    .wrap div:nth-of-type(1){
      height:100px;
      background:red;
      line-height: 150px;
      /*align-self:flex-end;*/
    }
    .wrap div:nth-of-type(2){
      height:50px;
      background:green;
      line-height: 50px;
    }
    .wrap div:nth-of-type(3){
      height:100px;
      background:yellow;
      line-height: 100px;
    }
    .wrap div:nth-of-type(4){
      height:30px;
      background:black;
      line-height: 30px;
      align-self:flex-end;
      color:white;
    }
  </style>
</head>
<body>
  <div class="wrap">
    <div>1</div>
    <div>2</div>
    <div>3</div>
    <div>4</div>
  </div>
</body>
</html>
Output

You can jump to the latest bin by adding /latest to your URL

Dismiss x
public
Bin info
anonymouspro
0viewers