Skip to content

Editor info link: "Annotation editor help", with an accessible description - #7596

Merged
santicomp2014 merged 1 commit into
mainfrom
editor-info-final-wording
Nov 12, 2026
Merged

santicomp2014 merged 1 commit into
mainfrom
editor-info-final-wording

Conversation

@santicomp2014

Copy link
Copy Markdown
Contributor

Sets the final wording of the info link above the annotation editor. The link is still behind the annotation_editor_info flag, so merging this changes nothing where the flag is off.

Part of hypothesis/product-backlog#1753. Follows #7594 and #7595.

What changes

Before (main, after #7595) After
Tooltip (title) Annotation Editor Help Annotation editor help
Accessible name About the Annotation editor. Learn what this text field is for. Opens Help Center article in a new tab. Annotation editor help
Accessible description Annotation Editor Help Learn what the annotation text field is for. Opens Help Center article in a new tab.

The name and description are what Chrome's accessibility tree computes for the link. A screen reader says "Annotation editor help, link", then the description.

How

  • aria-label is the same text as title, so what is shown on hover is what is announced, and what voice control listens for.
  • The description is a hidden element that the link points to with aria-describedby. A hidden element still describes what points to it, and is not read a second time as text after the link.
  • Its id comes from useId, so two annotations open for editing at once do not share one.
  • Because the link has a description of its own, the browser no longer uses the tooltip as the description. Before, the tooltip was read out twice.

What does not change

Where the link is, its icon, colour and size, where it goes, the new tab, the tab order, the feature flag and the Help panel rule. No dependency, build or boot script change.

Testing

MarkdownEditor tests:

  • The tooltip and the accessible name are "Annotation editor help".
  • The link is described by one element, in the same document, with the description above. That element is hidden, is outside the link and is not a tab stop.
  • Two editors in one tree get different ids, each pointing at the element next to its own link.

The checkAccessibility scenario for the link passes. The whole suite passes: 4,392 tests. Lint, typecheck and formatting pass.

🤖 Generated with Claude Code

The wording agreed for the info link above the annotation editor:

- Tooltip (`title`): "Annotation editor help"
- Accessible name (`aria-label`): "Annotation editor help"
- Accessible description: "Learn what the annotation text field is for.
  Opens Help Center article in a new tab."

The description is a `hidden` element the link points to with
`aria-describedby`, so it is read only as the description and not again
as text after the link. Its id comes from `useId`, so two editors open at
once do not share one. With a description of its own, the browser no
longer uses the tooltip as the description, so the tooltip is not read
out twice.

Part of hypothesis/product-backlog#1753.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@codecov

codecov Bot commented Nov 12, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 99.62%. Comparing base (fd3d79d) to head (83c2bc3).

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #7596   +/-   ##
=======================================
  Coverage   99.62%   99.62%           
=======================================
  Files         286      286           
  Lines       12061    12062    +1     
  Branches     2935     2935           
=======================================
+ Hits        12016    12017    +1     
  Misses         45       45           

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@santicomp2014
santicomp2014 merged commit 72526e9 into main Nov 12, 2026
2 of 4 checks passed
@santicomp2014
santicomp2014 deleted the editor-info-final-wording branch November 12, 2026 16:55
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.

2 participants