feat: Keyboard shortcuts improvements (#2790)

This commit is contained in:
Sivin Varghese 2021-08-26 15:55:58 +05:30 committed by GitHub
parent 69b0434bb7
commit d13c4ff8c5
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
7 changed files with 31 additions and 9 deletions

View file

@ -54,7 +54,7 @@ export default {
},
mounted() {
document.addEventListener('keydown', e => {
if (this.show && e.keyCode === 27) {
if (this.show && e.code === 'Escape') {
this.onClose();
}
});