<div style="width: 600px;">
<div class="flex-box border-sub-rb border-lt">
<div class="flex-cell1">种类</div>
<div class="flex-cell1">名称</div>
<div class="flex-cell2">描述</div>
</div>
<div class="flex-box border-l">
<div class="flex-cell1 border-b flex-cc" style="background-color: #ddd;border-color: red"><div>水果</div></div>
<div class="flex-cell3 border-r">
<div class="flex-box border-sub-bl">
<div class="flex-cell1 flex-cc"><div>香蕉</div></div>
<div class="flex-cell2 flex-cc" style="background-color: #ddd;border-color: red"><div>香蕉(学名:Musa nana Lour.)是芭蕉科、芭蕉属植物。植株丛生,具匐匍茎,矮型的高3.5米以下,一般高不及2米...</div></div>
</div>
<div class="flex-box border-sub-bl">
<div class="flex-cell1 flex-cc"><div>苹果</div></div>
<div class="flex-cell2 flex-cc"><div>苹果(Malus pumila Mill.),是落叶乔木,通常树木可高至15米,但栽培树木一般只高3-5米左右...</div></div>
</div>
</div>
</div>
<div class="flex-box">
<div class="flex-cell4 border-lb flex-cc"><div>其他</div></div>
<div class="flex-cell2 border-rbl flex-cc" style="background-color: #ddd;border-color: red"><div>--</div></div>
</div>
</div>
<style>
.flex-box {
display: flex;
flex-direction: row;
flex-wrap: nowrap;
color: #666;
font-size: 14px;
text-align: center;
box-sizing: border-box;
}
[class*=flex-cell] {
box-sizing: border-box;
}
.flex-cell1 {
width: 100px;
}
.flex-cell2 {
width: 400px;
padding: 12px 0;
}
.flex-cell3 {
width: 500px;
}
.flex-cell4 {
width: 200px;
}
.border-sub-rb [class*=flex-cell] {
border-right: 1px solid #ddd;
border-bottom: 1px solid #ddd;
padding: 12px 0;
}
.border-sub-bl [class*=flex-cell] {
border-bottom: 1px solid #ddd;
border-left: 1px solid #ddd;
}
.border-lt {
border-left: 1px solid #ddd;
border-top: 1px solid #ddd;
}
.border-lb {
border-left: 1px solid #ddd;
border-bottom: 1px solid #ddd;
}
.border-l {
border-left: 1px solid #ddd;
}
.border-rbl {
border-right: 1px solid #ddd;
border-bottom: 1px solid #ddd;
border-left: 1px solid #ddd;
}
.border-b {
border-bottom: 1px solid #ddd;
}
.border-r {
border-right: 1px solid #ddd;
}
.flex-cc {
display: flex;
flex-direction: row;
flex-wrap: nowrap;
justify-content: center;
align-items: center;
}
</style>
|