refactor: Tab组件优化 #9449

This commit is contained in:
wangjiahao
2024-08-14 16:20:13 +08:00
parent 2b908ed44f
commit e2d7445caa
5 changed files with 46 additions and 26 deletions

View File

@@ -28,6 +28,7 @@ import DeFullscreen from '@/components/visualization/common/DeFullscreen.vue'
import DeAppApply from '@/views/common/DeAppApply.vue'
import { useEmitt } from '@/hooks/web/useEmitt'
import { useUserStoreWithOut } from '@/store/modules/user'
import TabsGroup from '@/custom-component/component-group/TabsGroup.vue'
let nameEdit = ref(false)
let inputName = ref('')
let nameInput = ref(null)
@@ -332,6 +333,9 @@ const fullScreenPreview = () => {
>
<media-group></media-group>
</component-group>
<component-group is-label :base-width="115" icon-name="dv-tab" title="Tab">
<tabs-group :dv-model="dvModel"></tabs-group>
</component-group>
<component-group is-label :base-width="215" icon-name="dv-more-com" title="更多">
<more-com-group></more-com-group>
</component-group>

View File

@@ -576,7 +576,7 @@ const editStyle = computed(() => {
}
} else {
const result = {
...getCanvasStyle(canvasStyleData.value),
...getCanvasStyle(canvasStyleData.value, canvasId.value),
width: changeStyleWithScale(canvasStyleData.value.width) + 'px',
height: changeStyleWithScale(canvasStyleData.value.height) + 'px'
}

View File

@@ -530,7 +530,7 @@ const handleMouseDownOnShape = e => {
contentDisplay.value = true
}
// 仪表板进行Tab碰撞检查
dashboardActive.value && tabMoveInCheck()
tabMoveInCheck()
// 仪表板模式 会造成移动现象 当检测组件正在碰撞有效区内或者移入有效区内 则周边组件不进行移动
if (
dashboardActive.value &&