Merge pull request #13070 from dataease/pr@dev-v2@refactor_mobile-copy
refactor(仪表板): 复制的图片去掉原有移动端设置的样式
This commit is contained in:
commit
06257c4aed
@ -200,7 +200,12 @@ function deepCopyHelper(data, idMap) {
|
||||
const newComponentId = generateID()
|
||||
idMap[data.id] = newComponentId
|
||||
result.id = newComponentId
|
||||
// 复制清理移动端样式
|
||||
result.inMobile = false
|
||||
delete result.mStyle
|
||||
delete result.mEvents
|
||||
delete result.mPropValue
|
||||
delete result.mCommonBackgroud
|
||||
if (result.component === 'Group') {
|
||||
result.propValue.forEach((component, i) => {
|
||||
result.propValue[i] = deepCopyHelper(component, idMap)
|
||||
|
||||
@ -404,12 +404,15 @@ export const dvMainStore = defineStore('dataVisualization', {
|
||||
Object.keys(idMap).forEach(function (oldComponentId) {
|
||||
if (canvasViewInfoPre[oldComponentId]) {
|
||||
const newComponentId = idMap[oldComponentId]
|
||||
_this.canvasViewInfo[newComponentId] = {
|
||||
const newView = {
|
||||
...deepCopy(canvasViewInfoPre[oldComponentId]),
|
||||
id: newComponentId,
|
||||
linkageActive: false,
|
||||
jumpActive: false
|
||||
}
|
||||
newView['customAttrMobile'] = null
|
||||
newView['customStyleMobile'] = null
|
||||
_this.canvasViewInfo[newComponentId] = newView
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
@ -30,7 +30,7 @@ import CommonEvent from '@/custom-component/common/CommonEvent.vue'
|
||||
import CommonBorderSetting from '@/custom-component/common/CommonBorderSetting.vue'
|
||||
|
||||
const dvMainStore = dvMainStoreWithOut()
|
||||
const { dvInfo, batchOptStatus, curComponent } = storeToRefs(dvMainStore)
|
||||
const { dvInfo, batchOptStatus, mobileInPc } = storeToRefs(dvMainStore)
|
||||
const { t } = useI18n()
|
||||
|
||||
const state = {
|
||||
@ -445,8 +445,9 @@ watch(
|
||||
@onLabelChange="onLabelChange"
|
||||
/>
|
||||
</collapse-switch-item>
|
||||
// tooltip 为鼠标悬停 移动端看不到效果 不再单独配置
|
||||
<collapse-switch-item
|
||||
v-if="showProperties('tooltip-selector')"
|
||||
v-if="showProperties('tooltip-selector') && !mobileInPc"
|
||||
v-model="chart.customAttr.tooltip.show"
|
||||
:themes="themes"
|
||||
:change-model="chart.customAttr.tooltip"
|
||||
|
||||
@ -19,6 +19,7 @@ import 'vant/es/tabbar-item/style'
|
||||
import 'vant/es/tabbar/style'
|
||||
import 'vant/es/overlay/style'
|
||||
import 'vant/es/loading/style'
|
||||
import { useI18n } from '@/hooks/web/useI18n'
|
||||
|
||||
const activeTabbar = ref('home')
|
||||
const showLoading = ref(false)
|
||||
|
||||
Loading…
Reference in New Issue
Block a user