From 8bff4a297e89a3ad6235df31a3fc6ffc96158490 Mon Sep 17 00:00:00 2001 From: tophf Date: Thu, 23 Nov 2017 13:20:39 +0300 Subject: [PATCH] disallow Space as a colorpicker hotkey --- edit/colorpicker-helper.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/edit/colorpicker-helper.js b/edit/colorpicker-helper.js index e38433b1..30d9fbef 100644 --- a/edit/colorpicker-helper.js +++ b/edit/colorpicker-helper.js @@ -79,7 +79,7 @@ window.initColorpicker = () => { if (key === 'Enter' || key === 'Esc') { $('#help-popup .dismiss').onclick(); return; - } else if (/^((Shift-)?(Esc|Tab|[!-~])|(Shift-?|Ctrl-?|Alt-?|Cmd-?)*)$/.test(key)) { + } else if (/^(Space|(Shift-)?(Esc|Tab|[!-~])|(Shift-?|Ctrl-?|Alt-?|Cmd-?)*)$/.test(key)) { this.setCustomValidity('Not allowed'); } else { this.setCustomValidity('');