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-29 00:05:58 +08:00
* @LastEditTime: 2023-01-28 23:35:47
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;
2023-01-05 13:18:28 +08:00
}
2023-01-26 11:02:49 +08:00
#layout-container-down {
height: calc(100vh - 50px);
max-height: calc(100vh - 50px);
min-height: calc(100vh - 50px);
}
2023-01-05 13:18:28 +08:00
#layout-aside {
2023-01-19 18:01:35 +08:00
/* width: 175px; */
2023-01-26 00:01:29 +08:00
background-color: #2f4156;
2023-01-19 18:01:35 +08:00
overflow-x: hidden;
2023-01-26 11:02:49 +08:00
/* height: calc(100vh - 50px);
2023-01-25 15:13:03 +08:00
max-height: calc(100vh - 50px);
2023-01-26 11:02:49 +08:00
min-height: calc(100vh - 50px); */
height: 100%;
2023-01-05 13:18:28 +08:00
}
#layout-header {
2023-01-19 18:01:35 +08:00
height: 50px;
padding: 0px;
flex-grow: 0;
2023-01-05 13:18:28 +08:00
}
#layout-main {
2023-01-26 11:02:49 +08:00
padding: 0px;
height: 100%;
/* height: calc(100vh - 50px); */
2023-01-19 18:01:35 +08:00
/* flex-grow: 1; */
2023-01-26 01:57:31 +08:00
/* overflow: overlay; */
2023-01-08 00:03:51 +08:00
}
2023-01-05 13:18:28 +08:00
</style>