From a59441fb06bcbeacfe770e97d8a3022acb57bc0b Mon Sep 17 00:00:00 2001 From: Miodec Date: Fri, 30 Apr 2021 17:04:26 +0100 Subject: [PATCH] limited word length to 30 in zen mode. should fix #1316 --- src/js/input-controller.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/js/input-controller.js b/src/js/input-controller.js index a244a30a6..e9cd38d6e 100644 --- a/src/js/input-controller.js +++ b/src/js/input-controller.js @@ -625,10 +625,10 @@ function handleAlpha(event) { TestUI.setActiveWordTop(document.querySelector("#words .active").offsetTop); } - //max length of the input is 20 unless in zen mode + //max length of the input is 20 unless in zen mode then its 30 if ( - Config.mode == "zen" || - TestLogic.input.current.length < TestLogic.words.getCurrent().length + 20 + (Config.mode == "zen" && TestLogic.input.current.length < 30) || + (Config.mode !== "zen" && TestLogic.input.current.length < TestLogic.words.getCurrent().length + 20) ) { TestLogic.input.appendCurrent(event["key"]); }