desandro / draggabilly

:point_down: Make that shiz draggable

Home Page:https://draggabilly.desandro.com

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

pass handle as element???...

mikila85 opened this issue · comments

why not allow to pass handle as element???

Thanks for this feature request. Add a 👍 reaction to this issue if you would like to see handle be set with an Element. added. Do not add +1 comments — They will be deleted.

Draggabilly v3 has been released, now with updated handle behavior. You can set it to a single element or a Array or NodeList of elements

// select all .handle children with selector string
handle: '.handle'

// set as element
handle: element.querySelector('.handle')

// set as array or NodeList
handle: [ element.querySelector('.handle1'), element.querySelector('.handle2') ]

Please try it out and report back with any issues!