From 14bd5084ba9e0911fb61d817128e5eb0930ed82b Mon Sep 17 00:00:00 2001 From: =?utf8?q?Joshua=20R=C3=BCsweg?= Date: Thu, 31 Jan 2019 16:53:03 +0100 Subject: [PATCH] Fix pressing enter triggers trophy badge handler Fixes #2818 --- wcfsetup/install/files/acp/templates/trophyAdd.tpl | 2 +- .../install/files/js/WoltLabSuite/Core/Acp/Ui/Trophy/Badge.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/wcfsetup/install/files/acp/templates/trophyAdd.tpl b/wcfsetup/install/files/acp/templates/trophyAdd.tpl index 69fa975248..64c785a7ef 100644 --- a/wcfsetup/install/files/acp/templates/trophyAdd.tpl +++ b/wcfsetup/install/files/acp/templates/trophyAdd.tpl @@ -188,7 +188,7 @@
{lang}wcf.acp.trophy.type.badge{/lang}
- + {lang}wcf.global.button.edit{/lang} diff --git a/wcfsetup/install/files/js/WoltLabSuite/Core/Acp/Ui/Trophy/Badge.js b/wcfsetup/install/files/js/WoltLabSuite/Core/Acp/Ui/Trophy/Badge.js index d0fbb6228d..e49bac88de 100644 --- a/wcfsetup/install/files/js/WoltLabSuite/Core/Acp/Ui/Trophy/Badge.js +++ b/wcfsetup/install/files/js/WoltLabSuite/Core/Acp/Ui/Trophy/Badge.js @@ -20,7 +20,7 @@ define(['Core', 'Dictionary', 'Language', 'Ui/Dialog', 'WoltLabSuite/Core/Ui/Col */ init: function () { var iconContainer = elById('badgeContainer'); - elBySel('button', iconContainer).addEventListener(WCF_CLICK_EVENT, this._click.bind(this)); + elBySel('.button', iconContainer).addEventListener(WCF_CLICK_EVENT, this._click.bind(this)); _iconNameInput = elBySel('input[name="iconName"]', iconContainer); _iconColorInput = elBySel('input[name="iconColor"]', iconContainer); -- 2.20.1