mauricius / vue-draggable-resizable

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

Activate only via event #290

Open f0ursqu4r3 opened 3 years ago

f0ursqu4r3 commented 3 years ago

Would like to know if it is possible to only show the resize handles if the element is activated externally. As it is now, the handles show if the element is clicked, even when draggable and resizeable are inactive.

TitanFighter commented 3 years ago

Example from here: https://mauricius.github.io/vue-draggable-resizable/?path=/story/basic--basic-component-not-resizable

// Instead of "false" use some variable
<vue-draggable-resizable :resizable="false">
  <p>Basic component that is not resizable.</p>
</vue-draggable-resizable>

Set :resizable by default to "false" and change to "true" when you need.