try to add the gesture swipe to right
cleaned up some code