Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow handle to be an array of HTMLElement #166

Closed
wants to merge 1 commit into from

Conversation

kftang
Copy link

@kftang kftang commented Jul 27, 2017

I'm using Vue.js and found it to be quite difficult to get a selector string from an HTMLElement so something like this could make it much easier.

@desandro
Copy link
Owner

Thank you for this contribution! I like how this is a nice improvement. I like the feature, but I might implement differently to match Draggabilly's code style. I'll follow up in a subsequent release.

@desandro desandro closed this Dec 28, 2021
desandro added a commit that referenced this pull request Dec 29, 2021
- remove RequireJS docs
- version bump in README
@desandro
Copy link
Owner

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!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants