When the user clicks, you need one function that toggles the modality of the rules.
So the code has to switch between false and true for example for the isModalShwoing continuously (if it is true, it becomes false, if it is false, it becomes true). The showing and hiding text also switches and the rules themselves are shown or hidden. (All in one event listener)
i just noticed this. You’re using an assignment operator instead of a comparison operator.
Also note that isModalShowing will return a truthy so no comparison operator is even needed.
Finally, did you forget to do something that the step asked for? (hint: yes. Check!)
Edit: also, test your code. Is it working as you thought it would? (there’s another mistake)
If you have a question about a specific challenge as it relates to your written code for that challenge and need some help, click the Ask for Help button located on the challenge (it looks like a question mark). This button only appears if you have tried to submit an answer at least three times.
The Ask for Help button will create a new topic with all code you have written and include a link to the challenge also. You will still be able to ask any questions in the post before submitting it to the forum.