fix: focus on wrong element

pull/6480/head
Phuc Le 2024-09-26 10:45:15 +07:00
parent 6065a4e2b5
commit 8aeccb6ad5
1 changed files with 4 additions and 1 deletions

View File

@ -2549,7 +2549,10 @@ export default {
let spanIndex = null; let spanIndex = null;
for (let i = 0; i < focusableElements.length; i++) { for (let i = 0; i < focusableElements.length; i++) {
if (focusableElements[i].tagName === 'SPAN') spanIndex = i; if (focusableElements[i].tagName === 'SPAN') {
spanIndex = i;
break;
}
} }
focusableElements[spanIndex].focus(); focusableElements[spanIndex].focus();