85 lines
1.7 KiB
Vue
Raw Normal View History

2023-01-05 13:18:28 +08:00
<!--
* @Author: Kane
* @Date: 2023-01-04 11:05:44
* @LastEditors: Kane
2023-01-25 15:13:03 +08:00
* @LastEditTime: 2023-01-25 14:55:14
2023-01-08 00:03:51 +08:00
* @FilePath: \admin_system\src\layout\Index.vue
2023-01-05 13:18:28 +08:00
* @Description:
*
* Copyright (c) ${2022} by Kane, All Rights Reserved.
-->
<template>
2023-01-19 18:01:35 +08:00
<el-container id="layout-container">
<el-header id="layout-header">
<LayoutHeader />
</el-header>
<el-container id="layout-container-down">
<el-aside :width="asideWidth" id="layout-aside">
<LayoutAside />
</el-aside>
<el-main id="layout-main">
<LayoutMain />
</el-main>
2023-01-05 13:18:28 +08:00
</el-container>
2023-01-19 18:01:35 +08:00
</el-container>
2023-01-05 13:18:28 +08:00
</template>
<script>
import LayoutAside from "./components/Aside.vue";
import LayoutHeader from "./components/Header.vue";
import LayoutMain from "./components/Main.vue";
export default {
2023-01-19 18:01:35 +08:00
name: "layoutPage",
components: {
LayoutAside,
LayoutHeader,
LayoutMain,
},
computed: {
2023-01-23 17:11:30 +08:00
asideWidth()
{
2023-01-19 18:01:35 +08:00
const collapse = this.$store.state.app.asideBarCollapse;
2023-01-09 18:33:31 +08:00
2023-01-19 18:01:35 +08:00
return collapse === true ? "65px" : "180px";
},
},
2023-01-05 13:18:28 +08:00
};
</script>
<style scoped>
#layout-container {
2023-01-19 18:01:35 +08:00
height: 100vh;
max-height: 100vh;
/* overflow: hiddens; */
2023-01-05 13:18:28 +08:00
}
#layout-aside {
2023-01-19 18:01:35 +08:00
/* width: 175px; */
background-color: #223142;
overflow-x: hidden;
2023-01-25 15:13:03 +08:00
height: calc(100vh - 50px);
max-height: calc(100vh - 50px);
min-height: calc(100vh - 50px);
2023-01-05 13:18:28 +08:00
}
#layout-header {
2023-01-19 18:01:35 +08:00
height: 50px;
/* background-color: #77bc99; */
padding: 0px;
flex-grow: 0;
2023-01-05 13:18:28 +08:00
}
#layout-main {
2023-01-19 18:01:35 +08:00
background-color: #ecf2f9;
/* height: 0; */
/* flex-grow: 1; */
overflow: overlay;
2023-01-08 00:03:51 +08:00
}
#layout-container-down {
2023-01-19 18:01:35 +08:00
height: calc(100vh - 50px);
2023-01-23 17:11:30 +08:00
max-height: calc(100vh - 50px);
2023-01-25 11:37:24 +08:00
min-height: calc(100vh - 50px);
2023-01-05 13:18:28 +08:00
}
</style>