aboutsummaryrefslogtreecommitdiffstats
path: root/src/components/settings/SettingsLayout.jsx
diff options
context:
space:
mode:
authorLibravatar André Oliveira <37463445+SpecialAro@users.noreply.github.com>2022-07-19 12:52:31 +0100
committerLibravatar GitHub <noreply@github.com>2022-07-19 12:52:31 +0100
commit3bb1ca7825a0381ddd8dbe7f44f7dcf4a788b165 (patch)
tree6b414b9ef3be7656da1717b0d6def62e95d1fb90 /src/components/settings/SettingsLayout.jsx
parentfix: remove autoHibernate (diff)
downloadferdium-app-3bb1ca7825a0381ddd8dbe7f44f7dcf4a788b165.tar.gz
ferdium-app-3bb1ca7825a0381ddd8dbe7f44f7dcf4a788b165.tar.zst
ferdium-app-3bb1ca7825a0381ddd8dbe7f44f7dcf4a788b165.zip
Feature: Add Release Notes (#491)
Co-authored-by: Vijay A <vraravam@users.noreply.github.com> Co-authored-by: Ricardo Cino <ricardo@cino.io>
Diffstat (limited to 'src/components/settings/SettingsLayout.jsx')
-rw-r--r--src/components/settings/SettingsLayout.jsx4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/components/settings/SettingsLayout.jsx b/src/components/settings/SettingsLayout.jsx
index dea4bb387..989c428f2 100644
--- a/src/components/settings/SettingsLayout.jsx
+++ b/src/components/settings/SettingsLayout.jsx
@@ -8,6 +8,7 @@ import { Outlet } from 'react-router-dom';
8import ErrorBoundary from '../util/ErrorBoundary'; 8import ErrorBoundary from '../util/ErrorBoundary';
9import Appear from '../ui/effects/Appear'; 9import Appear from '../ui/effects/Appear';
10import Icon from '../ui/icon'; 10import Icon from '../ui/icon';
11import { isEscKeyPress } from '../../jsUtils';
11 12
12const messages = defineMessages({ 13const messages = defineMessages({
13 closeSettings: { 14 closeSettings: {
@@ -36,8 +37,7 @@ class SettingsLayout extends Component {
36 } 37 }
37 38
38 handleKeyDown(e) { 39 handleKeyDown(e) {
39 if (e.keyCode === 27) { 40 if (isEscKeyPress(e.keyCode)) {
40 // escape key
41 this.props.closeSettings(); 41 this.props.closeSettings();
42 } 42 }
43 } 43 }