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

Fix accessibility issue with lab result accordion headers #2422

Merged
merged 4 commits into from
Aug 23, 2024

Conversation

austin-hall-skylight
Copy link
Collaborator

PULL REQUEST

Summary

Change lab result accordion headers from h5 to h2 to fix accessibility issues (this doesn't change the way they look).

Related Issue

Fixes #2421

Additional Information

Checklist

  • If this code affects the other scrum team, have they been notified? (In Slack, as reviewers, etc.)

Copy link
Collaborator

@BobanL BobanL left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Although this does fix the issue of accessibility, I think we want to keep the structure of the heading orders.

For example all of the lab info labs should be H5 as they belong to that H4Lab Results from HOAG MEMORIAL HOSPITAL. I don't think they really stand on their own.
image
image

Similarly, the issue with the Condition Summary section. Each lab in that section logically fits under the Condition Summary header which is an h3.
image

Happy to pair with you if you need anything!

@austin-hall-skylight austin-hall-skylight changed the title Change lab result accordion headers from h5 to h2 Fix accessibility issue with lab result accordion headers Aug 22, 2024
@@ -43,7 +46,7 @@ export const AccordionLabResults: React.FC<AccordionLabResultsProps> = ({
content: content,
expanded: collapsedByDefault,
id: title,
headingLevel: "h5",
headingLevel,
className: `acc_item_${organizationId}`,
Copy link
Collaborator

@BobanL BobanL Aug 23, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Seems like the side nav is picking up the labs because it's not an h5 anymore. If you just add side-nav-ignore to this class name it should be resolved since no lab results should be in the sidenav anyways.
http://localhost:3000/view-data?id=1.2.840.114350.1.13.297.3.7.8.688883.567479#lab-results-from-hoag-memorial-hospital
image

Suggested change
className: `acc_item_${organizationId}`,
className: `acc_item_${organizationId} side-nav-ignore`,

Copy link
Collaborator

@BobanL BobanL left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for making those changes and fixing this issue!

@austin-hall-skylight austin-hall-skylight added this pull request to the merge queue Aug 23, 2024
Merged via the queue into main with commit 4ec0761 Aug 23, 2024
11 checks passed
@austin-hall-skylight austin-hall-skylight deleted the austin/2421-fix-accessibility branch August 23, 2024 15:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Lab results included in Condition Summary section fail accessibility tests
2 participants