kornelski / slip

Slip.js — UI library for manipulating lists via swipe and drag gestures
BSD 2-Clause "Simplified" License
2.44k stars 213 forks source link

add originalIndex to swipe's event.detail #31

Closed pandeiro closed 9 years ago

pandeiro commented 9 years ago

It is useful to know the index of the list item being swiped; this code uses the same structure as the reorder event to include this data at event.detail.originalIndex.

kornelski commented 9 years ago

Thanks. That's useful addition, but the code that finds the index looks like a duplicate from another function. Could you refactor both copies into a single function?

kornelski commented 9 years ago

Great :)

pandeiro commented 9 years ago

Cheers!

On Fri, Nov 21, 2014 at 7:09 PM, Kornel notifications@github.com wrote:

Great :)

— Reply to this email directly or view it on GitHub https://github.com/pornel/slip/pull/31#issuecomment-64037999.