Adds tap gesture recognizer to dismiss