ant-design/ant-design

Select renders an input with blank value causing screenreader accessibility concerns

Open

#52 987 ouverte le 27 févr. 2025

Voir sur GitHub
 (5 commentaires) (0 réactions) (0 assignés)TypeScript (98 031 stars) (54 612 forks)batch import
Inactivehelp wanted⌨️ Accessibility

Description

Reproduction link

Edit on CodeSandbox

Steps to reproduce

inspect value attribute of input element render by Select component

What is expected?

value attribute should have currently selected item label as its value

What is actually happening?

value attribute of input is blank input element rendered by Select component has empty value attribute causing screen reader accessibility issue.

Screenshot showing how screenreader reads the select box: Screenreader should also read currently selected value when select box is in focus.

Environment Info
antd 5.24.2
React 18.2
System Mac OS Version 15.1.1 (24B91
Browser Chrome Version 133.0.6943.127

Guide contributeur