add click function to make ul appear and disappear