-
-
Notifications
You must be signed in to change notification settings - Fork 257
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
Unable to use drag and drop functionality inside of TransformWrapper #460
Comments
Here is Workaround if u want to use it with react-dnd: 1. declare a state variable which deactivates the TransformWrapper:
2. use the variable on the TransformWrapper component:
3. use these event listener on the Draggable Element to enable and disable state:
For example, if this div is the root of your draggable component, it could look like this: One more thing I had to struggle with: |
Describe the bug
I'm trying to use
react-zoom-pan-pinch
withreact-dnd
but items nested within the are not responding to drag events. I've tried disabling panning to see if that helps but I am still unable to drag items. Items are responding to other mouse events such as mouseOver, click, mouseDown, mouseUp etc. I'm also seeing thecanDrag()
value from react-dnd for the draggable item returning as true. The nativeonDrag
prop on elements within the are also not triggering an event.Expected behavior
I would like to be able to able to both zoom, pan and drag and drop items within the
Desktop (please complete the following information):
The text was updated successfully, but these errors were encountered: