how to create an open and close menu