mauricius / vue-draggable-resizable

Vue3 Component for draggable and resizable elements.
https://mauricius.github.io/vue-draggable-resizable/
MIT License
3.33k stars 559 forks source link

aspectRatio seems to limit element's size to the parent's size #347

Closed tmclagen closed 2 years ago

tmclagen commented 2 years ago

When aspectRatio is set to true and you try and resize the element, it works like a charm. Until one of element's sides reaches the parent boundary. Then something strange happens: it either stops resizing or if you move the element outside the parent and try to resize it, the element pops back inside the parent box.

The issue can be reproduced on the official example page.

Unfortunately, I couldn't find any solution. And attempts to recreate custom aspectRatio failed miserably.

https://user-images.githubusercontent.com/51247307/163627569-73d5088c-2fbd-418d-a3da-d4c28eb009a3.mp4