fix: pressing "Escape" should close Dropdown, MultiSelect menu (#1473)

* fix(dropdown): close the menu when pressing "Escape"

* fix(multi-select): close the menu when pressing "Escape"
This commit is contained in:
metonym 2022-08-31 19:00:01 -07:00 committed by GitHub
commit 855ee06741
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 0 deletions

View file

@ -368,6 +368,8 @@
return { ...item, checked: !item.checked };
});
}
} else if (key === 'Escape') {
open = false;
}
}}"
on:focus="{() => {