Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found

Submitted

FAQ Page using html and css with js

Dipesh 130

@ddkogit

Desktop design screenshot for the FAQ accordion coding challenge

This is a solution for...

  • HTML
  • CSS
  • JS
1newbie
View challenge

Design comparison


SolutionDesign

Solution retrospective


Is this optimal way to do?? toggling class, or if there is other please feel free to recommend.

Community feedback

Daniel 🛸 44,230

@danielmrz-dev

Posted

Hello @ddkogit!

Your solution looks awesome!

You can add the background-color: #FAEEFF; and a background-image together to create that pattern. They will complement each other. It's not like "It's one OR the other", you can use both 😊

I hope it helps!

Other than that, great job!

Marked as helpful

0
P
Jax Teller 670

@piushbhandari

Posted

  • toggling class to show/hide content via javascript is a good approach and you'll see this as being best practice.

  • BTW, when i zoom out on your page, your layout gets messed up. i would change your styles on your body element to background-repeat: repeat-x; background-size: contain;. FYI, i would have the background image as a separate element

  • i would change <div class="question"> to <button type="button" class="question">. it's good to use semantic markup + as it stands right now your component is not accessible via keyboard and that's a no no. likely will need to update styles

Marked as helpful

0

Please log in to post a comment

Log in with GitHub
Discord logo

Join 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