StackExchange / StackExchange/Stacks

Icon-only tooltip-generating elements need screenreader text

Open
#841 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

accessibility
Dominant language
TypeScript
Stars
672
Forks
107
Avg merge
2d 12h
Merged PRs (30d)
26

Description

Scenario, you've got a button with an icon and a title attribute. You've wired it up to our tooltip controller.

The issue with this is our tooltip controller strips the title attribute entirely, building the content of the title into the popover.

Possible solution? Swap title for aria-label in the tooltip JS.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the tooltip controller in the JavaScript/TypeScript code and trace how the title attribute is removed and its content is used for the popover. Update the behavior so icon-only elements retain screenreader text while still generating the tooltip, then verify the tooltip and accessible label behavior.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript
Domain
accessibility, frontend
Issue type
Bug
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
50/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.