<div class="wrap flex">
  <div class="item w50per f-shrink0">1<br>flex-shrink:0</div>
  <div class="item w50per f-shrink1">2<br>flex-shrink:1<br>(初期値)</div>
  <div class="item w50per f-shrink2">3<br>flex-shrink:2</div>
  <div class="item w50per f-shrink2">4<br>flex-shrink:2</div>
</div>
/* 縮み率flex-shrink */
.f-shrink0 {
  -webkit-flex-shrink: 0;
  flex-shrink: 0;
}
.f-shrink1 {
  -webkit-flex-shrink: 1;
  flex-shrink: 1;
}
.f-shrink2 {
  -webkit-flex-shrink: 2;
  flex-shrink: 2;
}


/* 基本flex */
.flex {
  display: -webkit-flex;
  display: flex;
}
.f-wrap {
  -webkit-flex-wrap: wrap;
  flex-wrap: wrap;
}
/* flex以外のプロパティ */
h2,h3 {
  font-size: 1rem;
  font-weight: normal;
  margin: .5em;
}
p {
  font-size: .8rem;
}
.wrap {
  border: 1px solid #ccc;
}
.inWrap {
  border: 1px solid #ccc;
  width : 150px;
}
.item {
  border: 1px solid #ccc;
  padding: 5px;
  margin: 5px;
  text-align: center;
  box-sizing: border-box;
}
.miniItem {
  width: 30%;
  font-size: 10px;
  text-align: center;
  border: 1px solid #ccc;
  padding: 2px;
  margin: 2px;
  box-sizing: border-box;
}
.f-aliBase .miniItem {text-decoration: underline;}
.f-aliBase .miniItem:nth-child(2){font-size: 1em;}
.f-aliBase .miniItem:nth-child(3){font-size: 2em;}
.f-aliBase .miniItem:nth-child(4){font-size: 1.5em;}
.f-aliBase .miniItem:nth-child(5){font-size: 0.8em;}
.col3 {
  width: calc(100% / 3 - 10px);
}
.w100 {width: 100px;}
.w150 {
  width: 150px;
}
.h100 {
  height: 100px;
}
.w50per {width:50%;}

External CSS

This Pen doesn't use any external CSS resources.

External JavaScript

This Pen doesn't use any external JavaScript resources.