fix(components): [autocomplete] fix incorrect aria-controls value (#23350)

The aria-controls attribute was incorrectly set to the literal string 'id'
instead of the actual listbox ID, breaking screen reader association.
This commit is contained in:
E66
2026-01-08 21:04:22 +08:00
committed by GitHub
parent 09e157c01e
commit 9765e8c15e

View File

@@ -443,7 +443,7 @@ onMounted(() => {
;[
{ key: 'role', value: 'textbox' },
{ key: 'aria-autocomplete', value: 'list' },
{ key: 'aria-controls', value: 'id' },
{ key: 'aria-controls', value: listboxId.value },
{
key: 'aria-activedescendant',
value: `${listboxId.value}-item-${highlightedIndex.value}`,