Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Accordion Pattern: Questions about header structure and partially displayed panel content #2038

Open
gaurav5430 opened this issue Sep 11, 2021 · 1 comment
Labels
Feedback Issue raised by or for collecting input from people outside APG task force Pattern Page Related to a page documenting a Pattern question Issue asking a question

Comments

@gaurav5430
Copy link

I have some doubts which are not directly addressed in the description / example of the accordion Pattern

  • it is mentioned that the header has to be a button element, and everything inside the header should be a child of the button. Why is that? Can we not implement an accordion header where only the chevron / icon is interactive and shows/hides the panel (and the rest of the text is non interactive? if yes, would the same aria practices as mentioned in the example still apply ?

  • about the variant where partial text is always visible in the panel, would it still be ok to

    • use aria-expanded = false when the partial content is visible?
  • is it mandatory to use aria-controls even if the expanded content is just next in the DOM ?

@gaurav5430
Copy link
Author

gaurav5430 commented Sep 11, 2021

ohk, regarding the 3rd point, I guess I understand

the header button would be wrapped in a heading and hence the expanded panel would not be a direct sibling of the button, and so aria-controls would be helpful

@mcking65 mcking65 added documentation Feedback Issue raised by or for collecting input from people outside APG task force Pattern Page Related to a page documenting a Pattern question Issue asking a question labels Oct 4, 2021
@mcking65 mcking65 changed the title Accordion Pattern Accordion Pattern: Questions about header structure and partially displayed panel content Oct 4, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Feedback Issue raised by or for collecting input from people outside APG task force Pattern Page Related to a page documenting a Pattern question Issue asking a question
Development

No branches or pull requests

2 participants