-
Notifications
You must be signed in to change notification settings - Fork 983
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
Request: prevent dragging on custom handle #36
Comments
Something like |
One thing you could try would be to limit the draggable region in your table headers ( |
Just published Here's the default implementation: function shouldCancelStart(e) {
// Cancel sorting if the event target is an `input`, `textarea`, `select` or `option`
if (['input', 'textarea', 'select', 'option'].indexOf(e.target.tagName.toLowerCase()) !== -1) {
return true; // Return true to cancel sorting
}
} |
thanks! |
…clauderic#36, clauderic#41) props. Prevent right click from causing sort start (clauderic#46)
I need to implement table with column sorting and in addition to that - table headers should be sortable horizontally
For horizontal headers sorting I've used your great library
Now I need to handle column sorting by clicking arrows (you know, up|down arrows) inside every header row to sort ASC/DESC specific column.
To do this I need somehow cancel event propogation by clicking arrows so that react-sortable-hoc doesn't begin dragging. I've tried
but it does not prevent dragging :(
Is it possible?
The text was updated successfully, but these errors were encountered: