Reproduction link
https://ant.design/components/auto-complete#examples
Steps to reproduce
Type an available option in Typeahead
What is expected?
Typed option from the Typeahead dropdown should have aria-selected
set to true
What is actually happening?
Typed option from the Typeahead dropdown should have aria-selected
set to false
| Environment | Info |
| ------------ | ------------ |
| antd | undefined |
| React | Not react specific |
| System | Ubuntu 22.04.3 LTS |
| Browser | Chrome Version 122.0.6261.111 (Official Build) (64-bit) |
Select component is working fine but Typeahead lacks this accessibility.
5条答案
按热度按时间z3yyvxxp1#
@sreeram-s-zessta I can't see what is the issue exactly, I see that Autocomplete component has already araia-selected prop
You can see here
v2g6jxz62#
i try autocomplete, aria-selected="false" indeed
zi8p0yeb3#
@Othman2001 Yes the
aria-selected
attribute is available but the problem is the value of it. The value of the selected option is not updating to true.bybem2ql4#
Should add type
[
aria-${string}]?: string
?xv8emn3q5#
@MadCcc I am expecting
aria-selected
attribute on Typeahead options to have the right statustrue/false
based on the options selected in the Typeahead. Currently, the options have this attribute but the value is not updating totrue
even though a particular option is selected.