fix(ui): pixelRect should always be integer

This commit is contained in:
psychedelicious 2024-08-20 10:18:13 +10:00
parent 6db615ed5a
commit 7f05af4a68

View File

@ -658,8 +658,8 @@ export class CanvasTransformer {
const { minX, minY, maxX, maxY } = extents;
this.nodeRect = { ...rect };
this.pixelRect = {
x: rect.x + minX,
y: rect.y + minY,
x: Math.round(rect.x) + minX,
y: Math.round(rect.y) + minY,
width: maxX - minX,
height: maxY - minY,
};