vue-grid-layout icon indicating copy to clipboard operation
vue-grid-layout copied to clipboard

Slot for custom resize handle

Open vbaulac opened this issue 5 years ago • 0 comments

Hi, I'm using vue-grid-layout on a project that include iframes (like a youtube player) in resizable grid items.

I'm facing the issue that the "resize" & "resized" events on the gridItem are not enough, because the resize event is triggered only once the item is realy (virtualy) resized (like not the same width & height), and I need to hide the iframe as soon as the user mouseDown on the handle, otherwise the user can increase the size of an item, but not decrease it (the iframe being in the way of the mouse).

A possible workaround would be to use the ref="handle", or to find the handle thanks to its class (vue-resizable-handle), but I find this soutions not very prety or optimized.

I was wondering, why not using an optional slot in GridItem for the resizable handle ? So if I need to, I can define my own, with custom events on it.

What do you think ? Or maybe I am missing something obvious here..

Thank you

vbaulac avatar Oct 29 '20 09:10 vbaulac