Skip to content

LG-7771 Add correct screenreader tag for incomplete steps#7613

Merged
soniaconnolly merged 1 commit intomainfrom
sonia-lg-7771
Jan 11, 2023
Merged

LG-7771 Add correct screenreader tag for incomplete steps#7613
soniaconnolly merged 1 commit intomainfrom
sonia-lg-7771

Conversation

@soniaconnolly
Copy link
Contributor

🎫 Ticket

LG-7771

🛠 Summary of changes

Add INCOMPLETE StepStatus to StepIndicatorStep custom component and set statusText to step_indicator.status.not_complete

📜 Testing Plan

Provide a checklist of steps to confirm the changes.

  • Create an account
  • Navigate to the "Add your ID" page
  • Use a screen reader to read the step indicator details and/or inspect elements for usa-sr-only class.
  • Ensure that incomplete steps say "Not complete"

Co-authored-by: Eric Gade <eric.gade@gsa.gov>

changelog: User-Facing Improvements, Accessibility, Step indicator screen reader tags
@soniaconnolly soniaconnolly requested review from a team and aduth January 10, 2023 21:44
Copy link
Contributor

@aduth aduth left a comment

Choose a reason for hiding this comment

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

Good fix! Small note about test coverage, but otherwise LGTM. 👍

I also checked to confirm that this only appears to affect the JavaScript implementation, and the equivalent Rails View Component is working correctly.


const title = getByText('Step');
const status = getByText('step_indicator.status.current');
const status = getByText('step_indicator.status.not_complete');
Copy link
Contributor

Choose a reason for hiding this comment

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

Can we add a test case for the "current step" context?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Is there something you want covered in addition to lines 5-20 in this file?

Copy link
Contributor

Choose a reason for hiding this comment

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

Is there something you want covered in addition to lines 5-20 in this file?

Oh, good point! I totally missed we had test coverage for StepStatus.CURRENT already. I suppose it could be nice to have all of them covered (PENDING seems to be missing), but that's not in the scope of your work, so I wouldn't consider it a blocker.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

We were wondering about PENDING, and if it was really used. I'll go ahead and merge this, but there might be additional cleanup. Do you know what PENDING is for?

Copy link
Contributor

Choose a reason for hiding this comment

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

It was originally used for marking the GPO letter (verify by mail) step as pending, but I seem to recall there may have been some recent revisions to the flow where we no longer show the pending state. Let me dig that up, since it would be nice if we could drop the extra logic (I had a hard time re-wrapping my head around the differences between "incomplete", "current", and "pending").

Copy link
Contributor

Choose a reason for hiding this comment

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

It looks like the pending status was meant to have been removed as part of #6860. I can follow-up to clean up the lingering references, since I'm to blame for not having done it in the first place 😅


const title = getByText('Step');
const status = getByText('step_indicator.status.current');
const status = getByText('step_indicator.status.not_complete');
Copy link
Contributor

Choose a reason for hiding this comment

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

Is there something you want covered in addition to lines 5-20 in this file?

Oh, good point! I totally missed we had test coverage for StepStatus.CURRENT already. I suppose it could be nice to have all of them covered (PENDING seems to be missing), but that's not in the scope of your work, so I wouldn't consider it a blocker.

@soniaconnolly soniaconnolly marked this pull request as ready for review January 11, 2023 19:39
@soniaconnolly soniaconnolly merged commit 4abff09 into main Jan 11, 2023
@soniaconnolly soniaconnolly deleted the sonia-lg-7771 branch January 11, 2023 19:41
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.

3 participants