Skip to content

Conversation

francinelucca
Copy link
Member

@francinelucca francinelucca commented Sep 27, 2024

Relates to https://github.com/github/primer/issues/3457

Currently the TooltipV2 only adds aria-hidden=true if tooltip is of type label. This is causing voiceover to announce the tooltip twice for "description" type tooltips: once for the tooltiped element's aria-describedby, and once again for the actual tooltip item. This PR Adds aria-hidden=true always to the Tooltip component to prevent screen readers from announcing the tooltip twice on MAC voiceover.

Changelog

New

  • aria-hidden=true in description type test

Changed

  • aria-hidden=true is always added to TooltipV2 component
  • Update ActionMenu tests to account for aria-hidden tooltip

Rollout strategy

  • Patch release
  • Minor release
  • Major release; if selected, include a written rollout or migration plan
  • None; if selected, include a brief description as to why

Testing & Reviewing

Test production story against deployment. Notice tooltip is read out twice when using mac voiceover on prod but only once on deployment

Merge checklist

Copy link

changeset-bot bot commented Sep 27, 2024

🦋 Changeset detected

Latest commit: 6952f99

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@primer/react Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

Copy link
Contributor

github-actions bot commented Sep 27, 2024

size-limit report 📦

Path Size
packages/react/dist/browser.esm.js 96.69 KB (-0.09% 🔽)
packages/react/dist/browser.umd.js 97.06 KB (-0.03% 🔽)

@francinelucca francinelucca changed the title fix(Tooltip): always add aria-hidden fix(TooltipV2): always add aria-hidden Sep 27, 2024
@francinelucca francinelucca added the staff Author is a staff member label Sep 27, 2024
@github-actions github-actions bot temporarily deployed to storybook-preview-5041 September 27, 2024 16:54 Inactive
@francinelucca francinelucca added the update snapshots 🤖 Command that updates VRT snapshots on the pull request label Sep 27, 2024
@github-actions github-actions bot removed the update snapshots 🤖 Command that updates VRT snapshots on the pull request label Sep 27, 2024
@github-actions github-actions bot temporarily deployed to storybook-preview-5041 September 27, 2024 18:56 Inactive
@francinelucca francinelucca added the update snapshots 🤖 Command that updates VRT snapshots on the pull request label Sep 27, 2024
@github-actions github-actions bot removed the update snapshots 🤖 Command that updates VRT snapshots on the pull request label Sep 27, 2024
…description-can-be-missed-or-encountered-twice
@primer-integration
Copy link

👋 Hi from github/github! Your integration PR is ready: https://github.com/github/github/pull/344522

@francinelucca francinelucca marked this pull request as ready for review October 4, 2024 16:10
@francinelucca francinelucca requested a review from a team as a code owner October 4, 2024 16:10
@francinelucca francinelucca requested a review from jonrohan October 4, 2024 16:10
@jonrohan jonrohan requested review from broccolinisoup and removed request for jonrohan October 7, 2024 18:29
Copy link
Member

@broccolinisoup broccolinisoup left a comment

Choose a reason for hiding this comment

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

Thank you! It looks great - are there any commits at dotcom that need to go with this PR? @francinelucca

@francinelucca
Copy link
Member Author

Thank you! It looks great - are there any commits at dotcom that need to go with this PR? @francinelucca

Yes! dotcom PR is up here

…description-can-be-missed-or-encountered-twice
…description-can-be-missed-or-encountered-twice
Copy link
Contributor

github-actions bot commented Oct 8, 2024

👋 Hi, this pull request contains changes to the source code that github/github depends on. If you are GitHub staff, we recommend testing these changes with github/github using the integration workflow. Thanks!

@github-actions github-actions bot added the integration-tests: recommended This change needs to be tested for breaking changes. See https://arc.net/l/quote/tdmpakpm label Oct 8, 2024
@francinelucca francinelucca added integration-tests: passing Changes in this PR do NOT cause breaking changes in gh/gh and removed integration-tests: recommended This change needs to be tested for breaking changes. See https://arc.net/l/quote/tdmpakpm labels Oct 8, 2024
@francinelucca francinelucca added this pull request to the merge queue Oct 9, 2024
Merged via the queue into main with commit 4da550e Oct 9, 2024
47 checks passed
@francinelucca francinelucca deleted the francinelucca/3457-prctooltip-best-practice-description-can-be-missed-or-encountered-twice branch October 9, 2024 20:58
@primer primer bot mentioned this pull request Oct 9, 2024
@primer primer bot mentioned this pull request Oct 18, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
integration-tests: passing Changes in this PR do NOT cause breaking changes in gh/gh staff Author is a staff member status: review needed
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants