Fix dropdown combobox focus (#447)

* fix(combo-box): selecting a different combobox should focus the input

* fix(dropdown): selecting a different dropdown should focus the button

* fix(combo-box): focus input if related target attribute is not "searchbox"
This commit is contained in:
Eric Liu 2020-12-05 11:36:41 -08:00 committed by GitHub
commit f6877f3809
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 7 additions and 8 deletions

View file

@ -189,11 +189,6 @@
change(-1);
}
}}"
on:blur="{({ relatedTarget }) => {
if (relatedTarget) {
ref.focus();
}
}}"
disabled="{disabled}"
translateWithId="{translateWithId}"
id="{id}"
@ -213,6 +208,7 @@
on:click="{() => {
selectedId = item.id;
selectedIndex = i;
ref.focus();
}}"
on:mouseenter="{() => {
highlightedIndex = i;