perf: perf style (#89)

perf: perf style
This commit is contained in:
一万
2021-10-31 20:24:57 +08:00
committed by GitHub
parent 0fb7b5e983
commit 9ddf449ea7
20 changed files with 161 additions and 166 deletions

View File

@@ -74,9 +74,18 @@ const transitionMain = defineComponent({
v-if="keepAlive"
:include="usePermissionStoreHook().cachePageList"
>
<component :is="Component" :key="route.fullPath" />
<component
:is="Component"
:key="route.fullPath"
class="main-content"
/>
</keep-alive>
<component v-else :is="Component" :key="route.fullPath" />
<component
v-else
:is="Component"
:key="route.fullPath"
class="main-content"
/>
</transitionMain>
</el-scrollbar>
<div v-else>
@@ -85,9 +94,18 @@ const transitionMain = defineComponent({
v-if="keepAlive"
:include="usePermissionStoreHook().cachePageList"
>
<component :is="Component" :key="route.fullPath" />
<component
:is="Component"
:key="route.fullPath"
class="main-content"
/>
</keep-alive>
<component v-else :is="Component" :key="route.fullPath" />
<component
v-else
:is="Component"
:key="route.fullPath"
class="main-content"
/>
</transitionMain>
</div>
</template>
@@ -108,4 +126,8 @@ const transitionMain = defineComponent({
min-height: 100vh;
position: relative;
}
.main-content {
margin: 24px;
}
</style>