修复-侧边工具
This commit is contained in:
parent
906559134e
commit
9674c68d11
|
@ -73,9 +73,8 @@ const list = computed(() => props.data.map((o,i) => {
|
||||||
}))
|
}))
|
||||||
onMounted(() => {
|
onMounted(() => {
|
||||||
posBtnAll = btnRef.value.getBoundingClientRect()
|
posBtnAll = btnRef.value.getBoundingClientRect()
|
||||||
hPost.value = posBtnAll.height
|
hPost.value = Math.round(posBtnAll.height)
|
||||||
|
curNode = sessionStore?.get?.('subject.curNode')
|
||||||
curNode = sessionStore.get('subject.curNode')
|
|
||||||
})
|
})
|
||||||
// === 方法 ===
|
// === 方法 ===
|
||||||
// 获取颜色索引
|
// 获取颜色索引
|
||||||
|
@ -97,7 +96,7 @@ const clickHandel = (o, e) => {
|
||||||
isVisible.value = !isColse // 相同的按钮且打开状态,点击关闭
|
isVisible.value = !isColse // 相同的按钮且打开状态,点击关闭
|
||||||
activeObj.value = o
|
activeObj.value = o
|
||||||
const nodeH = parseInt(node.height / 2) // 高度的一半
|
const nodeH = parseInt(node.height / 2) // 高度的一半
|
||||||
topPos.value = parseInt(node.top) - posBtnAll.top + nodeH
|
topPos.value = Math.round(parseInt(node.top) - posBtnAll.top + nodeH)
|
||||||
}
|
}
|
||||||
emit('change', o)
|
emit('change', o)
|
||||||
}
|
}
|
||||||
|
@ -149,8 +148,8 @@ const closeActive = () =>{
|
||||||
--top: 30px;
|
--top: 30px;
|
||||||
--height: 40vh;
|
--height: 40vh;
|
||||||
position: fixed;
|
position: fixed;
|
||||||
inset: 50% 75px auto auto;
|
inset: 0 75px auto auto;
|
||||||
transform: translateY(-50%);
|
// transform: translateY(-50%);
|
||||||
background-color: #121212;
|
background-color: #121212;
|
||||||
padding: 10px;
|
padding: 10px;
|
||||||
border-radius: 4px;
|
border-radius: 4px;
|
||||||
|
|
Loading…
Reference in New Issue