修复了滚动条

This commit is contained in:
luyuan 2020-09-25 16:54:03 +08:00
parent ec13ae4a4e
commit 5bf4b36049
Signed by: theluyuan
GPG Key ID: A7972FD973317FF3
3 changed files with 16 additions and 3 deletions

View File

@ -12,4 +12,5 @@
text-overflow: ellipsis; text-overflow: ellipsis;
white-space: nowrap; white-space: nowrap;
} }
</style> </style>

View File

@ -37,6 +37,7 @@
.nav{ .nav{
display: flex; display: flex;
background-color: #fff; background-color: #fff;
min-width: 1366px;
.logo{ .logo{
width: 171px; width: 171px;
height: 57px; height: 57px;

View File

@ -1,5 +1,5 @@
<template> <template>
<div class="mine"> <div class="mine" :style="{height:height + 'px'}">
<NavTop style="flex-shrink:0"></NavTop> <NavTop style="flex-shrink:0"></NavTop>
<div class="body"> <div class="body">
<Menu></Menu> <Menu></Menu>
@ -13,9 +13,10 @@
.mine{ .mine{
display: flex; display: flex;
flex-direction: column; flex-direction: column;
height: 100vh;
.body{ .body{
display: flex; display: flex;
width: 100%;
min-width: 1366px;
height: calc(100% - 57px); height: calc(100% - 57px);
.container{ .container{
width: calc(100% - 171px); width: calc(100% - 171px);
@ -28,7 +29,7 @@
} }
</style> </style>
<script lang="ts"> <script lang="ts">
import { defineComponent } from 'vue'; import { defineComponent, onMounted, ref } from 'vue';
import Menu from "@/components/Menu.vue"; import Menu from "@/components/Menu.vue";
import NavTop from "@/components/NavTop.vue" import NavTop from "@/components/NavTop.vue"
@ -39,6 +40,16 @@ export default defineComponent({
}, },
setup(){ setup(){
console.log(1) console.log(1)
const height = ref(0);
onMounted(() => {
height.value = document.documentElement.clientHeight;
})
window.onresize=function(){
height.value = document.documentElement.clientHeight;
}
return {
height
}
} }
}) })
</script> </script>