JedWatson / JedWatson/react-select

Placeholder linked to Input through aria-describedby

Open
#5,651 1 comment 2 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

issue/bug-unconfirmed
Dominant language
TypeScript
Stars
28k
Forks
4.1k
PR merge metrics
No merged PRs in 30d

Description

Placeholder and Input from react-select are linked not via label, aria-label or aria-labeledby, but through aria-describedby - which is absolutely incorrect.

Raw HTML from https://react-select.com/home examples

<div id="react-select-11-placeholder">Select...</div>
<div>
<input class="" autocapitalize="none" autocomplete="off" autocorrect="off" id="react-select-11-input" spellcheck="false" tabindex="0" type="text" aria-autocomplete="list" aria-expanded="false" aria-haspopup="true" role="combobox" aria-describedby="react-select-11-placeholder">
</div>

See the difference:

I believe the current implementation should be redone to make Placeholder linked to Input via aria-labeledby

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 by reproducing the raw markup from the react-select home examples and tracing how the Placeholder and Input are rendered. Compare the generated relationship with the linked MDN guidance; done means the placeholder is associated with the input using the appropriate labeling mechanism rather than aria-describedby, with the rendered markup verified.

Written by the indexing model from the issue text.

Assessment

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

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.