Merge pull request #11176 from dataease/pr@dev-v2@refactor_menu

refactor(数据大屏): 优化过滤组件右键菜单显示位置,防止过滤组件右键菜单偏移太多问题
This commit is contained in:
王嘉豪 2024-07-25 15:02:03 +08:00 committed by GitHub
commit 1e70a03e56
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -526,6 +526,10 @@ const handleContextMenu = e => {
//
if (!curComponent.value || (curComponent.value && !curComponent.value.editing)) {
if (['VQuery'].includes(curComponent.value.component)) {
left = left * curBaseScale.value + 150
top = top * curBaseScale.value + curComponent.value.style.top * (1 - curBaseScale.value)
}
contextmenuStore.showContextMenu({ top, left, position: 'canvasCore' })
const iconDom = document.getElementById('close-button')
if (iconDom) {