🐞 fix: 修复画布大小计算逻辑

This commit is contained in:
yuanxin 2023-10-19 13:37:58 +08:00
parent 72a6fabfee
commit a34164c7d7

View File

@ -159,11 +159,11 @@ const dragCanvas = (e: any) => {
const canvasBox = () => { const canvasBox = () => {
const layoutDom = document.getElementById('go-chart-edit-layout') const layoutDom = document.getElementById('go-chart-edit-layout')
if (layoutDom) { if (layoutDom) {
// // clientWidthclientHeight
const scrollW = 20 //
return { return {
height: layoutDom.clientHeight - scrollW, height: layoutDom.clientHeight - thick,
width: layoutDom.clientWidth - scrollW width: layoutDom.clientWidth - thick
} }
} }
return { return {