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

I found a bug #317

Open 2419930554 opened 3 years ago

2419930554 commented 3 years ago

When I add an event to restore the default value of the drag box (W, h, x, y), a bug will appear when certain conditions occur

The problem appears in the method calcdraglimits in the source code of the Vue file. The obtained this.width is the result of the last drag, not the result of restoring the default value

Therefore, my suggestion is to put the X and Y monitoring functions in watch under the W and H monitoring functions in watch. I hope the author can repair them as soon as possible

mauricius commented 2 years ago

Please provide an example using CodeSandbox or an equivalent service.