fix: increase rounding snap tolerance to 4px to prevent background line bleed when padding is 0
This commit is contained in:
@@ -408,8 +408,8 @@ function centerRectInBounds(params: { bounds: RenderRect; size: Size; maxSize: S
|
||||
if (
|
||||
maxWidth >= boundsWidth &&
|
||||
maxHeight >= boundsHeight &&
|
||||
Math.abs(boundsWidth - resolvedWidth) <= 1 &&
|
||||
Math.abs(boundsHeight - resolvedHeight) <= 1
|
||||
Math.abs(boundsWidth - resolvedWidth) <= 4 &&
|
||||
Math.abs(boundsHeight - resolvedHeight) <= 4
|
||||
) {
|
||||
return {
|
||||
x: boundsX,
|
||||
|
||||
Reference in New Issue
Block a user