Design comparison
SolutionDesign
Solution retrospective
What specific areas of your project would you like help with?
I dont know how to make the buttons turn from plus to minus. also why do i have to double click to use the buttons for the first time.
Community feedback
- @Alex-Archer-IPosted 6 months ago
Hi! The variable, you are using to detect status of the question, is initially set to 0. So at first click function executes
else
condition which setdisplay
tonone
.To change icons you can use
img
tag inside thebutton
and change it'ssrc
attribute via JS.Also I recommend you to add
cursor: pointer
rule to buttons for better user experience.Happy coding =)
0
Please log in to post a comment
Log in with GitHubJoin our Discord community
Join thousands of Frontend Mentor community members taking the challenges, sharing resources, helping each other, and chatting about all things front-end!
Join our Discord