From 5fb98ea512d71da78aa34dc843507e0456efee3c Mon Sep 17 00:00:00 2001 From: Matthias Schmidt Date: Fri, 15 Feb 2019 09:29:47 +0100 Subject: [PATCH] Prevent page jump when opening icon dialog for icon form field See #2545 --- com.woltlab.wcf/templates/__iconFormField.tpl | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/com.woltlab.wcf/templates/__iconFormField.tpl b/com.woltlab.wcf/templates/__iconFormField.tpl index fe3cecf0a4..b8c8d2535d 100644 --- a/com.woltlab.wcf/templates/__iconFormField.tpl +++ b/com.woltlab.wcf/templates/__iconFormField.tpl @@ -22,7 +22,9 @@ input.value = iconName; }; - button.addEventListener('click', function() { + button.addEventListener('click', function(event) { + event.preventDefault(); + UiStyleFontAwesome.open(callback); }); }); -- 2.20.1