<template>
    <div class="content">
        <e-row :gutter="24">
            <e-col :span="24" class="box-card">
                <e-card shadow="always" :body-style="bodyStyle">
                    <div slot="header" class="clearfix">
                        <span>常见页面布局</span>
                    </div>
                    <div>
                        <e-container direction="vertical">
                            <e-header>Header</e-header>
                            <e-main>Main</e-main>
                        </e-container>

                        <e-container direction="vertical">
                            <e-header>Header</e-header>
                            <e-main>Main</e-main>
                            <e-footer>Footer</e-footer>
                        </e-container>

                        <e-container direction="horizontal">
                            <e-aside width="200px">Aside</e-aside>
                            <e-main>Main</e-main>
                        </e-container>

                        <e-container direction="vertical">
                            <e-header>Header</e-header>
                            <e-container direction="horizontal">
                                <e-aside width="200px">Aside</e-aside>
                                <e-main>Main</e-main>
                            </e-container>
                        </e-container>

                        <e-container direction="vertical">
                            <e-header>Header</e-header>
                            <e-container direction="horizontal">
                                <e-aside width="200px">Aside</e-aside>
                                <e-container direction="vertical">
                                <e-main>Main</e-main>
                                <e-footer>Footer</e-footer>
                                </e-container>
                            </e-container>
                        </e-container>

                        <e-container direction="horizontal">
                            <e-aside width="200px">Aside</e-aside>
                            <e-container direction="vertical">
                                <e-header>Header</e-header>
                                <e-main>Main</e-main>
                            </e-container>
                        </e-container>

                        <e-container direction="horizontal">
                            <e-aside width="200px">Aside</e-aside>
                            <e-container direction="vertical">
                                <e-header>Header</e-header>
                                <e-main>Main</e-main>
                                <e-footer>Footer</e-footer>
                            </e-container>
                        </e-container>
                    </div>
                </e-card>
            </e-col>
            <e-col :span="24" class="box-card">
                <e-card shadow="always">
                    <div slot="header" class="clearfix">
                        <span>响应式布局</span>
                    </div>
                    <div>
                        <e-container style="height: 500px; border: 1px solid #eee" direction="horizontal">
                            <e-aside width="200px" style="background-color: rgb(238, 241, 246)">
                                <e-menu :default-openeds="['1', '3']">
                                <e-submenu index="1">
                                    <template slot="title"><i class="el-icon-message"></i>导航一</template>
                                    <e-menu-item-group>
                                    <template slot="title">分组一</template>
                                    <e-menu-item index="1-1">选项1</e-menu-item>
                                    <e-menu-item index="1-2">选项2</e-menu-item>
                                    </e-menu-item-group>
                                    <e-menu-item-group title="分组2">
                                    <e-menu-item index="1-3">选项3</e-menu-item>
                                    </e-menu-item-group>
                                    <e-submenu index="1-4">
                                    <template slot="title">选项4</template>
                                    <e-menu-item index="1-4-1">选项4-1</e-menu-item>
                                    </e-submenu>
                                </e-submenu>
                                <e-submenu index="2">
                                    <template slot="title"><i class="el-icon-menu"></i>导航二</template>
                                    <e-menu-item-group>
                                    <template slot="title">分组一</template>
                                    <e-menu-item index="2-1">选项1</e-menu-item>
                                    <e-menu-item index="2-2">选项2</e-menu-item>
                                    </e-menu-item-group>
                                    <e-menu-item-group title="分组2">
                                    <e-menu-item index="2-3">选项3</e-menu-item>
                                    </e-menu-item-group>
                                    <e-submenu index="2-4">
                                    <template slot="title">选项4</template>
                                    <e-menu-item index="2-4-1">选项4-1</e-menu-item>
                                    </e-submenu>
                                </e-submenu>
                                <e-submenu index="3">
                                    <template slot="title"><i class="el-icon-setting"></i>导航三</template>
                                    <e-menu-item-group>
                                    <template slot="title">分组一</template>
                                    <e-menu-item index="3-1">选项1</e-menu-item>
                                    <e-menu-item index="3-2">选项2</e-menu-item>
                                    </e-menu-item-group>
                                    <e-menu-item-group title="分组2">
                                    <e-menu-item index="3-3">选项3</e-menu-item>
                                    </e-menu-item-group>
                                    <e-submenu index="3-4">
                                    <template slot="title">选项4</template>
                                    <e-menu-item index="3-4-1">选项4-1</e-menu-item>
                                    </e-submenu>
                                </e-submenu>
                                </e-menu>
                            </e-aside>
                            
                            <e-container direction="vertical">
                                <e-header style="text-align: right; font-size: 12px">
                                <e-dropdown>
                                    <i class="el-icon-setting" style="margin-right: 15px"></i>
                                    <e-dropdown-menu slot="dropdown">
                                    <e-dropdown-item>查看</e-dropdown-item>
                                    <e-dropdown-item>新增</e-dropdown-item>
                                    <e-dropdown-item>删除</e-dropdown-item>
                                    </e-dropdown-menu>
                                </e-dropdown>
                                <span>王小虎</span>
                                </e-header>
                                
                                <e-main>
                                <e-table :data="tableData">
                                    <e-table-column prop="date" label="日期" width="140">
                                    </e-table-column>
                                    <e-table-column prop="name" label="姓名" width="120">
                                    </e-table-column>
                                    <e-table-column prop="address" label="地址">
                                    </e-table-column>
                                </e-table>
                                </e-main>
                            </e-container>
                            </e-container>
                    </div>
                </e-card>
            </e-col>
        </e-row>
    </div>
</template>
<script>

export default {
    components: {},
    data() {
        const item = {
        date: '2016-05-02',
        name: '王小虎',
        address: '上海市普陀区金沙江路 1518 弄'
      };
        return {
            tableData: Array(20).fill(item)
        }
    },
    mounted() {
    },
    methods: {
    }
}
</script>
  
<style>
.marginLeft {
    margin-left: 10px
}
.el-aside{
    padding: 0;
    margin-bottom: 0px;
}
.content {
    height: 100%;
    padding: 30px;
    background:#fff;
}

.block {
    display: inline-block;
    margin-left: 10px;
}

.box-card .el-col{
    margin-bottom:10px;
}

/* 样式 */
/* .el-container {
    display: flex;
    flex-direction: column;
    flex: 1;
    flex-basis: auto;
    box-sizing: border-box;
    min-width: 0;
} */
.el-header, .el-footer {
    background-color: #B3C0D1;
    color: #333;
    text-align: center;
    line-height: 60px;
}
  
.el-aside {
    background-color: #D3DCE6;
    color: #333;
    text-align: center;
    line-height: 200px;
}

.el-header {
    background-color: #B3C0D1;
    color: #333;
    line-height: 60px;
  }
  
  .el-aside {
    color: #333;
  }

.el-main {
    background-color: #E9EEF3;
    color: #333;
    text-align: center;
    line-height: 160px;
}
  
body > .el-container {
    margin-bottom: 40px;
}
  
  .el-container:nth-child(5) .el-aside,
  .el-container:nth-child(6) .el-aside {
    line-height: 260px;
  }
  
  .el-container:nth-child(7) .el-aside {
    line-height: 320px;
  }
  </style>
