Skip to content

Conversation

amyleadem
Copy link
Contributor

@amyleadem amyleadem commented Sep 7, 2023

Summary

Updated the screen reader readout to say "Official" instead of "An official". When read out on a screen reader, the statement "An official website of [Agency name]" can sound like "UNofficial website of [Agency name]". To minimize confusion, we hid the word "An" from screen readers with aria-hidden.

Breaking change

⚠️ This requires a markup change for English-language implementations of the identifier.

In English versions of the identifier component, users should update their markup to hide the word "An" from screen readers by wrapping the word in a span with an aria-hidden attribute.

Before

<p class="usa-identifier__identity-disclaimer">
    An official website of the <a href="">[Parent agency]</a>
</p>

After

<p class="usa-identifier__identity-disclaimer">
    <span aria-hidden="true">An </span>official website of the <a href="">[Parent agency]</a>
</p>

Related issue

Closes #5362

Related pull requests

Changelog PR

Preview link

Problem statement

When read out on a screen reader, the statement "An official website of the [Agency name]" can sound like "UNofficial website of [Agency name]".

Solution

To minimize the impact on visual presentation, we created a screen reader-only solution that hides "An" from the readout. Instead the screen reader will now read out "official website of the [Agency name]".

Testing and review

  • Using a variety of browsers and screen readers, confirm that the screen reader readout is intuitive and makes sense.
  • Confirm that the new aria change is added only to English versions of the component.
  • Consider: Is it confusing that it is only for English implementations? Anything we should do to add clarity?

Copy link

@amycole501 amycole501 left a comment

Choose a reason for hiding this comment

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

Sounds good in JAWS; I hear "official" instead of "an official" which did used to sound like "unofficial".

Copy link
Contributor

@mahoneycm mahoneycm left a comment

Choose a reason for hiding this comment

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

Lgtm! I like the direction you took with the fix!

  • Sounds great with VoiceOver across browsers
  • Spanish variant is unexpected

If we include a guidance update as to why we left it out, we can maybe add instructions to consider all languages used by the site and to reduce confusion for screen reader users where possible

@mejiaj
Copy link
Contributor

mejiaj commented Oct 11, 2023

Have we discussed the possibility of removing it all together so that it's Official website…? That way the language would be consistent regardless of translation.

CC @amycole501 @thisisdano

@thisisdano
Copy link
Contributor

We have discussed changes to the boilerplate, but banner language is a big question that we'll need to address comprehensively and consistently. I do think we'll want to ask this question, and build evidence toward a better solution, but I also think we'll want to leave the discussion until after the Web Components version is out so we can consider the implementation angle at the same time.

@amyleadem
Copy link
Contributor Author

@thisisdano Does this mean that you want to leave the visible text as is and leave this as a screen reader-only fix for now?

cc: @mejiaj

Copy link
Contributor

@mejiaj mejiaj left a comment

Choose a reason for hiding this comment

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

Code looks good, I compared component to Identifier on develop storybookJS.

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.

USWDS - Enhancement: Improve "An official website" text in identifier
5 participants