前端布局
<!DOCTYPE html>
<head>
<meta charset="utf-8">
<link rel="stylesheet" href="https://unpkg.com/element-ui/lib/theme-chalk/index.css">
</head>
<body>
<div id="app">
<el-row>
<el-col :span="24" class="light">{{col24}}</el-col>
</el-row>
<el-row>
<el-col :span="12" class="light">{{col12}}</el-col>
<el-col :span="12" class="dark">{{col12}}</el-col>
</el-row>
</div>
</body>
<script src="https://unpkg.com/vue@2/dist/vue.js">
</script>
<script src="https://unpkg.com/element-ui/lib/index.js">
</script>
<script>
new Vue({
el: '#app',
data: function() {
return {
col24: 'col-24',
col12: 'col-12',
}
}
})
</script>
<style>
.el-row {
margin-bottom: 20px;
&:last-child {
margin-bottom: 0;
}
}
.el-col {
border-radius: 0px;
}
.light {
height:30px;
background-color: lightgreen;
text-align: center;
max-height: 30px;
}
.dark {
height:30px;
background-color: darkgreen;
text-align: center;
max-height: 30px;
}
</style>