react-sortablejs icon indicating copy to clipboard operation
react-sortablejs copied to clipboard

[bug]

Open MeXaaR opened this issue 5 years ago • 3 comments

Describe the bug Hi, I am not sure it is a bug or a bad usage but we have been working on this problem for a few days. so, We have 3 lists, one is "unsorted" items and 2 are here to sort items. we can put items in the sorted but not in the unsorted. this one disappear when there is nothing in it. A button to enable and disable the DND and a button to add a new "sorted" list. Only one state to handle all of this. This was how our app is made. So everything works perfectly, but when you add a new list, you can't DND something from it or in it.the first lists are disabled (but the state is enabled). if you add two lists, you can DND between them two but not with the others. and all of this doesn't happen if you don't have this disabled props

To Reproduce Steps to reproduce the behavior:

  1. Go to https://codesandbox.io/s/hardcore-hertz-fo0m8
  2. Enable DND on the left side
  3. Play with the lists
  4. Add a new list
  5. First problem
  6. Add a new list
  7. try DND between the new two lists

Expected behavior The expected behavior can be reproduce on the right side

Versions - Look in your package.json for this information: react-sortable = 2.0.11 react = 16.12.0

MeXaaR avatar Apr 02 '20 15:04 MeXaaR

Thank you for the example! I can clearly see this is because props cannot currently change at runtime.

Basically a duplicate of #118

waynevanson avatar Apr 08 '20 05:04 waynevanson

okay thx :) any chances of fixing it ?

MeXaaR avatar Apr 15 '20 12:04 MeXaaR

@MeXaaR its on the list.

Feel free to provide a PR!

waynevanson avatar Apr 16 '20 02:04 waynevanson