diff --git a/src/js/input-controller.js b/src/js/input-controller.js index c55f31665..24eebdfb9 100644 --- a/src/js/input-controller.js +++ b/src/js/input-controller.js @@ -398,6 +398,9 @@ function handleChar(char, charIndex) { char + TestLogic.input.current.substring(charIndex + 1); + MonkeyPower.addPower(thisCharCorrect); + TestStats.incrementAccuracy(thisCharCorrect); + if (!thisCharCorrect && Misc.trailingComposeChars.test(resultingWord)) { TestLogic.input.current = resultingWord; TestUI.updateWordElement(); @@ -405,9 +408,6 @@ function handleChar(char, charIndex) { return; } - MonkeyPower.addPower(thisCharCorrect); - TestStats.incrementAccuracy(thisCharCorrect); - if (!thisCharCorrect) { TestStats.incrementKeypressErrors(); TestStats.pushMissedWord(TestLogic.words.getCurrent()); diff --git a/src/js/layouts.js b/src/js/layouts.js index e1944c1b3..aafdbc2e6 100644 --- a/src/js/layouts.js +++ b/src/js/layouts.js @@ -514,6 +514,17 @@ const layouts = { "ـ", "ظ'", "ط", "ذئ", "دء", "زأ", "رإ", "وؤ", "،>", ".<", "/؟", " " ] + }, + brasileiro_nativo: { + keymapShowTopRow: false, + iso: true, + keys: [ + "=+", "1!", "2@", "3#", "4$", "5%", "6¨", "7&", "8*", "9(", "0)", "[{", "]}", + "/?", ",<", ".>", "hH", "xX", "wW", "lL", "tT", "cC", "pP", "~^", "-_", "'\"", + "iI", "eE", "aA", "oO", "uU", "mM", "dD", "sS", "rR", "nN", "´`", + ";:", "yY", "çÇ", "jJ", "bB", "kK", "qQ", "vV", "gG", "fF", "zZ", "\\|", + " " + ] } } export default layouts;