dimanche 26 juillet 2020

Nav won't open again after it's been clicked on and closed

I can't figure out how to make my navbar be able to open again by clicking on it after it has already been opened and closed.

My code is working just fine regarding hiding nav (translateX(100%), then showing nav once clicked on the burger, and then closing nav (again translateX(100%)) when clicking on a link linking to the same page.

However, once all that is done, when I click on the burger again it wont open the nav like it did the first time.

I'm guessing I should write a loop, but I'm having trouble figuring it out completely, so I would appriciate help or any hints on how to do it. Thanks!




Aucun commentaire:

Enregistrer un commentaire