Hello everyone! :) I'm testing out a "swipe to dismiss" interaction, like as seen on Official Twitter app and somewhere else.
From this point, I managed to create a simple up or down dismiss interaction, based on measuring the current Y position of a layer to its original Y position.
Eventually, I'd like to add a couple of conditions, so the layer moves back to it's original position when you swipe it a little bit. In the meanwhile, swiping a lot will make the layer move away from the screen.
What I'm having trouble with is to make it return to the original position. ;/
Is there any good reference to look at?