forked from github/dataease
fix(仪表板): 修复快速反复切换tab组件页,部分组件可能变形问题
This commit is contained in:
parent
683462ae90
commit
14f5d753f2
@ -15,7 +15,7 @@
|
|||||||
:border-color="noBorderColor"
|
:border-color="noBorderColor"
|
||||||
:border-active-color="borderActiveColor"
|
:border-active-color="borderActiveColor"
|
||||||
>
|
>
|
||||||
<template :key="tabItem.name" v-for="(tabItem, index) in element.propValue">
|
<template :key="tabItem.name" v-for="tabItem in element.propValue">
|
||||||
<el-tab-pane
|
<el-tab-pane
|
||||||
class="el-tab-pane-custom"
|
class="el-tab-pane-custom"
|
||||||
:lazy="isEditMode"
|
:lazy="isEditMode"
|
||||||
@ -54,6 +54,14 @@
|
|||||||
</el-dropdown>
|
</el-dropdown>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
</el-tab-pane>
|
||||||
|
</template>
|
||||||
|
<div
|
||||||
|
style="position: absolute; width: 100%; height: 100%"
|
||||||
|
:key="tabItem.name + '-content'"
|
||||||
|
v-for="(tabItem, index) in element.propValue"
|
||||||
|
:class="{ 'switch-hidden': editableTabsValue !== tabItem.name }"
|
||||||
|
>
|
||||||
<de-canvas
|
<de-canvas
|
||||||
v-if="isEdit && !mobileInPc"
|
v-if="isEdit && !mobileInPc"
|
||||||
:ref="'tabCanvas_' + index"
|
:ref="'tabCanvas_' + index"
|
||||||
@ -78,8 +86,7 @@
|
|||||||
:outer-scale="scale"
|
:outer-scale="scale"
|
||||||
:outer-search-count="searchCount"
|
:outer-search-count="searchCount"
|
||||||
></de-preview>
|
></de-preview>
|
||||||
</el-tab-pane>
|
</div>
|
||||||
</template>
|
|
||||||
</de-custom-tab>
|
</de-custom-tab>
|
||||||
<el-dialog
|
<el-dialog
|
||||||
title="编辑标题"
|
title="编辑标题"
|
||||||
@ -549,7 +556,6 @@ onBeforeMount(() => {
|
|||||||
}
|
}
|
||||||
.el-tab-pane-custom {
|
.el-tab-pane-custom {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
height: 100%;
|
|
||||||
}
|
}
|
||||||
.canvas-move-in {
|
.canvas-move-in {
|
||||||
border: 2px dotted transparent;
|
border: 2px dotted transparent;
|
||||||
@ -570,4 +576,9 @@ onBeforeMount(() => {
|
|||||||
display: flex;
|
display: flex;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.switch-hidden {
|
||||||
|
opacity: 0;
|
||||||
|
z-index: -1;
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
|
Loading…
Reference in New Issue
Block a user