Skip to content

Commit

Permalink
Add documentation for 'id' to accordion component
Browse files Browse the repository at this point in the history
The extra documentation for the 'id' attribute that was present in the
Nunjucks options table for the accordion has been added to the 'How It
Works Section'. This is because if a user is just using the HTML of the
accordion component, then they might not encounter the additional
documentation provided for the 'id' attribute.

This addresses issue #1073.
  • Loading branch information
patrickpatrickpatrick committed May 14, 2024
1 parent dfc6e12 commit e7ac344
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/components/accordion/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,8 @@ There are 2 ways to use the accordion component. You can use HTML or, if you’r

The accordion component uses JavaScript. When JavaScript is not available, users will see all the content displayed with the section labels as headings.

If you are using HTML, you must add an 'id' attribute to the parent div of the accordion. It must be unique across the service's domain to maintain the persistent expanded state of the accordion

### Section heading buttons

An accordion will usually start with all sections hidden. To show a section, the user can interact anywhere in the heading button.
Expand Down

0 comments on commit e7ac344

Please sign in to comment.