Design comparison
Solution retrospective
I used "input type:checkbox" to simulate accordion with the pseudo-class :checked, but i like to heard others ideas. Thanks!!
Community feedback
- @brasspetalsPosted about 4 years ago
I also used the "checkbox hack" for this challenge, but you can use radio buttons in a similar way if you only want to have one question open at a time. I have also learned that you can use the
details
element (something I didn't know existed), which you can learn more about here in the MDN documentation.Also, nice job on this challenge! It responds great, and kudos for finding a CSS only solution! 🎉
2@GusjafoPosted about 4 years ago@brasspetals Thank you very much for your comment, it was very helpful. After looking at other solutions, I noticed that they only opened one item at a time, so I was wondering how to do it and I got your answer! Thank you! The details element was also unknown to me. Something that took me some time to solve due to the positioning of the different figures. Isn't there an element that does it automatically? 😅 Greetings and thanks again for your time.
0@brasspetalsPosted about 4 years ago@Gusjafo Getting the images right was very tricky and took me a long time as well - it seems we came up with very similar solutions! I asked if there was a better way to place the images when I posted my solution, but haven't gotten an answer. 🤷♀️ If I ever find out - I'll come back here and let you know!
1
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