Fix aria hidden#1160
Conversation
Add class: usa-accordion-content-collapsed Update accordion.js: Add remove class-based solution
|
Adding @ducklet - There you go, I think. If you look at the "replace lost functionality" commit - you should be able to see what was done with the JavaScript - jQuery makes it pretty simple when you know the functions and classes. :) |
|
Fixes #1120 |
|
@joshbruce looks good to me :) thank you!! |
|
@joshbruce we just merged the somewhat large change to not check in the compiled When you rebase, none of the files in |
# Conflicts: # dist/css/uswds.css # dist/css/uswds.min.css # dist/css/uswds.min.css.map # dist/js/uswds.js # dist/js/uswds.min.js # dist/js/uswds.min.js.map # docs/_scss/components/_accordions.scss # docs/_scss/core/_base.scss # docs/_scss/lib/_bourbon.scss # docs/_scss/lib/css3/_radial-gradient.scss # docs/assets/img/alerts/error.png # docs/assets/img/alerts/info.png # docs/assets/img/alerts/success.png # docs/assets/img/arrow-right.png # docs/assets/img/correct8.png # docs/assets/img/correct9.png # docs/assets/img/favicons/favicon-114.png # docs/assets/img/favicons/favicon-144.png # docs/assets/img/favicons/favicon-192.png # docs/assets/img/favicons/favicon-57.png # docs/assets/img/favicons/favicon-72.png # docs/assets/img/favicons/favicon.png # docs/assets/img/logo-img.png # docs/assets/img/minus.png # docs/assets/img/social-icons/png/facebook25.png # docs/assets/img/social-icons/png/rss25.png # docs/assets/img/social-icons/png/youtube15.png # docs/assets/js/vendor/uswds.min.js
|
@msecret - Don't merge this if it integrates. I need to add the new class to the pages that use accordions. Just wanted to see quickly what would happen. |
Typography page was the only page found with collapsed accordions not generated by Javascript.
|
Hey @joshbruce, we're doing a little branch switcheroo and will need to close this since the branch names will change. We would still like to get these changes into |
|
@rogeruiz - No worries. Couple of questions:
|
|
@joshbruce the branch switch is complete! Feel free to re-open.
I believe there were changes on the
Cleaning up the above should be all that's needed. |
Remove from _base.scss: aria-hidden, display:none
Add class to _accordion.scss: usa-accordion-content-collapsed, display:none
Update accordion preview classes
Update accordion.js: Add remove class to expand and collapse.
Update styleguide.js to display code accordion collapsed on load.