diff --git a/src/components/map/MapInteraction.js b/src/components/map/MapInteraction.js index 13e40d7..0e4c377 100644 --- a/src/components/map/MapInteraction.js +++ b/src/components/map/MapInteraction.js @@ -51,8 +51,10 @@ function MapInteraction({ const mapImageRef = useRef(); function handleResize(width, height) { - setStageWidth(width); - setStageHeight(height); + if (width > 0 && height > 0) { + setStageWidth(width); + setStageHeight(height); + } } const containerRef = useRef();