From 0b56c5abf87b3713fff827fedd3ea00c830dd4d5 Mon Sep 17 00:00:00 2001 From: Evan You Date: Mon, 12 Mar 2018 11:40:35 -0400 Subject: [PATCH] fix: fix keyName checking for arrow keys in IE11 fix #7806 --- src/compiler/codegen/events.js | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/src/compiler/codegen/events.js b/src/compiler/codegen/events.js index 58e7b014760..4f9222466ad 100644 --- a/src/compiler/codegen/events.js +++ b/src/compiler/codegen/events.js @@ -22,10 +22,11 @@ const keyNames: { [key: string]: string | Array } = { tab: 'Tab', enter: 'Enter', space: ' ', - up: 'ArrowUp', - left: 'ArrowLeft', - right: 'ArrowRight', - down: 'ArrowDown', + // #7806: IE11 uses key names without `Arrow` prefix for arrow keys. + up: ['Up', 'ArrowUp'], + left: ['Left', 'ArrowLeft'], + right: ['Right', 'ArrowRight'], + down: ['Down', 'ArrowDown'], 'delete': ['Backspace', 'Delete'] }