Skip to content

A fully responsive and accessible FAQ accordion component built with semantic HTML, modern CSS, and vanilla JavaScript. This project focuses on web accessibility (a11y) using proper ARIA attributes like aria-expanded, aria-controls, and keyboard navigation support to ensure a smooth experience for keyboard and screen reader users.

Notifications You must be signed in to change notification settings

Piyush-Rajput7/Accessible-Faq-section

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

5 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

Frontend Mentor - FAQ Accordion

This is a solution to the FAQ accordion challenge on Frontend Mentor. Frontend Mentor challenges help you improve your coding skills by building realistic projects.

πŸš€ Live Site

πŸ”— View Live Website
πŸ“ View Repository

πŸ“Έ Screenshot

Desktop view

!Desktop Screenshot(./assets/images/screenshot.png)

πŸ› οΈ Built With

  • Semantic HTML5
  • Modern CSS (Flexbox, media queries)
  • JavaScript (DOM manipulation + accessibility)
  • Mobile-first workflow
  • Frontend Mentor Starter Files

πŸ’‘ Features

  • Responsive layout for mobile and desktop
  • Accessible FAQ interaction using:
    • aria-expanded
    • aria-controls
    • role="region"
  • Smooth toggle animation (optional enhancement)
  • Keyboard navigable
  • Custom hover and focus states

πŸ€“ What I Learned

  • How to structure HTML with accessibility in mind
  • The importance of aria-* attributes in building inclusive UI
  • Efficiently toggling UI states using JavaScript
  • Writing clean, reusable styles using BEM / utility-first approach

⏭️ Future Improvements

  • Add animations for open/close effect
  • Store active FAQ state in localStorage
  • Add dark mode

πŸ“š Useful Resources

πŸ™‹β€β™‚οΈ Author

🧠 Challenge by

This challenge was created by Frontend Mentor. Thank you for providing amazing real-world practice challenges!

About

A fully responsive and accessible FAQ accordion component built with semantic HTML, modern CSS, and vanilla JavaScript. This project focuses on web accessibility (a11y) using proper ARIA attributes like aria-expanded, aria-controls, and keyboard navigation support to ensure a smooth experience for keyboard and screen reader users.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published