forked from github/dataease
Merge pull request #12572 from dataease/pr@dev-v2@refactor_tab-move
refactor(仪表板、数据大屏): tab内组件支持向上移出
This commit is contained in:
commit
7e3e6d2421
@ -521,13 +521,14 @@ const handleMouseDownOnShape = e => {
|
||||
const left = curX - startX + startLeft
|
||||
pos['top'] = top
|
||||
pos['left'] = left
|
||||
// 非主画布非分组画布的情况 需要检测是否从Tab中移除组件(向左移除30px 或者向右移除30px)
|
||||
// 非主画布非分组画布的情况 需要检测是否从Tab中移除组件(向左移除30px 或者向右移除30px 向左移除30px)
|
||||
// 因为仪表板中组件向下移动可能只是为了挤占空间 不一定是为了移出 这里无法判断明确意图 暂时支不支持向下移出
|
||||
// 大屏和仪表板暂时做位置算法区分 仪表板暂时使用curX 因为缩放的影响 大屏使用 tab位置 + 组件位置(相对内部画布)+初始触发点
|
||||
if (
|
||||
!isMainCanvas(canvasId.value) &&
|
||||
!isGroupCanvas(canvasId.value) &&
|
||||
!isGroupArea.value &&
|
||||
(left < -30 || left + componentWidth - canvasWidth > 30)
|
||||
(top < -30 || left < -30 || left + componentWidth - canvasWidth > 30)
|
||||
) {
|
||||
contentDisplay.value = false
|
||||
dvMainStore.setMousePointShadowMap({
|
||||
|
Loading…
Reference in New Issue
Block a user