cashier-mer/src/layout/index.vue
weipengfei 7efc4ec3af 更新
2024-04-06 17:08:15 +08:00

56 lines
1.2 KiB
Vue

<script setup>
import myHeader from "./myHeader.vue";
import myAside from "./myAside.vue";
</script>
<template>
<div class="common-layout">
<el-container>
<el-header>
<myHeader></myHeader>
</el-header>
<el-container>
<el-aside width="100px">
<myAside></myAside>
</el-aside>
<el-main>
<router-view v-slot="{ Component }" class="my-main">
<transition name="el-fade-in-linear">
<component :is="Component"></component>
</transition>
</router-view>
<!-- <transition name="el-zoom-in-top">
<router-view class="my-main"></router-view>
</transition> -->
</el-main>
</el-container>
</el-container>
</div>
</template>
<style scoped lang="scss">
.common-layout {
width: 100vw;
height: 100vh;
background-color: #001529;
.el-header {
color: #fff;
}
.el-aside {
color: #fff;
}
.el-main {
background-color: #f5f5f5;
width: calc(100vw - 100px);
height: calc(100vh - 60px);
border-radius: 2rem 0 0 0;
overflow-y: scroll;
.my-main {
height: 100%;
width: 100%;
}
}
}
</style>