From 77048e3df3640ee8c8e8e38a1490dcac4eb37df3 Mon Sep 17 00:00:00 2001 From: Mahdi Mohammadi Date: Sun, 4 Jun 2017 11:23:21 +0100 Subject: [PATCH] ignore invalid and let him proceed --- js/type.js | 27 +++++++++++++-------------- 1 file changed, 13 insertions(+), 14 deletions(-) diff --git a/js/type.js b/js/type.js index 1c144fb..8d72817 100644 --- a/js/type.js +++ b/js/type.js @@ -101,8 +101,6 @@ function setup(data, mime) { readOnly: true, autofocus: true, extraKeys: { - Up: () => {}, - Down: () => {}, Left: () => {}, Right: () => {} } @@ -274,24 +272,25 @@ function moveToEndOfPreviousLine() { } function isComplete() { +console.log('isComplete'); if (!areAllNextLinesEmpty()) { if (incompleteMark.lines.length != 0) { return false; } } - for (var i = 0; i < invalids.length; i++) { - let arr = invalids[i]; - if (arr) { - for (var j = 0; j < arr.length; j++) { - // invalid marks are sometimes cleared but not removed - // this can be checked by checking mark.lines.length != 0 - if (arr[j] && arr[j].lines.length != 0) { - return false; - } - } - } - } + // for (var i = 0; i < invalids.length; i++) { + // let arr = invalids[i]; + // if (arr) { + // for (var j = 0; j < arr.length; j++) { + // // invalid marks are sometimes cleared but not removed + // // this can be checked by checking mark.lines.length != 0 + // if (arr[j] && arr[j].lines.length != 0) { + // return false; + // } + // } + // } + // } return true; }