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

Bug on dropping card when using laneSortFunction

Open belgamo opened this issue 5 years ago • 3 comments

Describe the bug When drag the card, rt dropping the wrong card instead of the dragged card when using laneSortFunction.

To Reproduce Steps to reproduce the behavior:

  1. Pass laneSortFunction={(a, b) => a.title.localeCompare(b.title)} to RT
  2. Try drag any card from any lane that contains more than 3 cards to any other lane

Expected behavior That the dropped card was the dragged card

Screenshots https://giphy.com/gifs/eGmgQnA1Ju7wklFRX1

Desktop (please complete the following information):

  • OS: Windows 10
  • Firefox 70

Additional context I don't know why, but when I remove concat() from line 54 of the Line.js file, the problem does not occur. https://github.com/rcdexta/react-trello/blob/a797c4d20f25ed41e0d5243a31616858b294d906/src/controllers/Lane.js#L52

belgamo avatar Oct 24 '19 04:10 belgamo

+1

akzarma avatar Apr 21 '20 04:04 akzarma

not sure if this is the same issue but I've noticed that when a sortFunction is defined and I drag a card, it's the card below it that ends up getting moved.

jLouzado avatar Nov 18 '20 19:11 jLouzado

+1

Sangammm avatar Mar 10 '21 10:03 Sangammm