From 360f1cd250378a54d0305464111b2af57fb79731 Mon Sep 17 00:00:00 2001 From: Michael Telatynski <7t3chguy@googlemail.com> Date: Sun, 7 May 2017 20:57:54 +0100 Subject: [PATCH] completely missed the ESC check I need sleep --- src/components/views/dialogs/BaseDialog.js | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/components/views/dialogs/BaseDialog.js b/src/components/views/dialogs/BaseDialog.js index d567a0ba9a..e7b8a687f5 100644 --- a/src/components/views/dialogs/BaseDialog.js +++ b/src/components/views/dialogs/BaseDialog.js @@ -59,8 +59,10 @@ export default React.createClass({ // Don't let key down events get any further, so they only trigger this and nothing more _onKeyDown: function(e) { - e.stopPropagation(); - e.preventDefault(); + if (e.keyCode === KeyCode.ESCAPE) { + e.stopPropagation(); + e.preventDefault(); + } }, // Must be when the key is released (and not pressed) otherwise componentWillUnmount