From 654f811b57b730126f1baf0628e0bd00c4617f6f Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 21 Jul 2020 00:05:16 +0000 Subject: [PATCH 01/38] Bump lodash from 4.17.15 to 4.17.19 in /functions Bumps [lodash](https://github.com/lodash/lodash) from 4.17.15 to 4.17.19. - [Release notes](https://github.com/lodash/lodash/releases) - [Commits](https://github.com/lodash/lodash/compare/4.17.15...4.17.19) Signed-off-by: dependabot[bot] --- functions/package-lock.json | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) diff --git a/functions/package-lock.json b/functions/package-lock.json index b26868b3a..62ce36148 100644 --- a/functions/package-lock.json +++ b/functions/package-lock.json @@ -1889,9 +1889,9 @@ } }, "lodash": { - "version": "4.17.15", - "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.15.tgz", - "integrity": "sha512-8xOcRHvCjnocdS5cpwXQXVzmmh5e5+saE2QGoeQmbKmRS6J3VQppPOIt0MnmE+4xlZoumy0GPG0D0MVIQbNA1A==" + "version": "4.17.19", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.19.tgz", + "integrity": "sha512-JNvd8XER9GQX0v2qJgsaN/mzFCNA5BRe/j8JN9d+tWyGLSodKQHKFicdwNYzWwI3wjRnaKPsGj1XkBjx/F96DQ==" }, "lodash.at": { "version": "4.6.0", @@ -2855,13 +2855,15 @@ "http-parser-js": ">=0.5.1", "safe-buffer": ">=5.1.0", "websocket-extensions": ">=0.1.1" + }, + "dependencies": { + "websocket-extensions": { + "version": "0.1.4", + "resolved": "https://registry.npmjs.org/websocket-extensions/-/websocket-extensions-0.1.4.tgz", + "integrity": "sha512-OqedPIGOfsDlo31UNwYbCFMSaO9m9G/0faIHj5/dZFDMFqPTcx6UwqyOy3COEaEOg/9VsGIpdqn62W5KhoKSpg==" + } } }, - "websocket-extensions": { - "version": ">=0.1.4", - "resolved": "https://registry.npmjs.org/websocket-extensions/-/websocket-extensions-0.1.4.tgz", - "integrity": "sha512-OqedPIGOfsDlo31UNwYbCFMSaO9m9G/0faIHj5/dZFDMFqPTcx6UwqyOy3COEaEOg/9VsGIpdqn62W5KhoKSpg==" - }, "which": { "version": "1.3.1", "resolved": "https://registry.npmjs.org/which/-/which-1.3.1.tgz", From eb6b1dbb3f05850874a08bd6a2ebc7baa68c6032 Mon Sep 17 00:00:00 2001 From: throwawaywords <64502440+throwawaywords@users.noreply.github.com> Date: Tue, 21 Jul 2020 07:58:31 +0300 Subject: [PATCH 02/38] Added Norman, Halmak, qwpr and QGMLWB layouts. --- public/js/layouts.js | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) diff --git a/public/js/layouts.js b/public/js/layouts.js index 68db144ce..78aa7a8fd 100644 --- a/public/js/layouts.js +++ b/public/js/layouts.js @@ -34,5 +34,33 @@ const layouts = { "uU","iİ","eE","aA","üÜ","tT","kK","mM","lL","yY","şŞ", "jJ","öÖ","vV","cC","çÇ","zZ","sS","bB",".:",",;", " " + ], + norman: [ + "`~","1!","2@","3#","4$","5%","6^","7&","8*","9(","0)","-_","=+", + "qQ","wW","dD","fF","kK","jJ","uU","rR","lL",";:","[{","]}","\\|", + "aA","sS","eE","tT","gG","yY","nN","iI","oO","hH","'\"", + "zZ","xX","cC","vV","bB","pP","mM",",<",".>","/?", + " " + ], + halmak: [ + "`~","1!","2@","3#","4$","5%","6^","7&","8*","9(","0)","-_","=+", + "wW","lL","rR","bB","zZ",";:","qQ","uU","dD","jJ","[{","]}","\\|", + "sS","hH","nN","tT",",<",".>","aA","eE","oO","iI","'\"", + "fF","mM","vV","cC","/?","gG","pP","xX","kK","yY", + " " + ], + qwerty: [ + "`~","1!","2@","3#","4$","5%","6^","7&","8*","9(","0)","-_","=+", + "qQ","gG","mM","lL","wW","bB","yY","uU","vV",";:","[{","]}","\\|", + "dD","sS","tT","nN","rR","iI","aA","eE","oO","hH","'\"", + "zZ","xX","cC","fF","jJ","kK","pP",",<",".>","/?", + " " + ], + qwpr: [ + "`~","1!","2@","3#","4$","5%","6^","7&","8*","9(","0)","-_","=+", + "qQ","wW","pP","rR","fF","yY","uU","kK","lL",";:","[{","]}","\\|", + "aA","sS","dD","tT","gG","hH","nN","iI","oO","eE","'\"", + "zZ","xX","cC","vV","bB","jJ","mM",",<",".>","/?", + " " ] } From 696b9a617bb419b6d0a473e92f61bf521e1d7d9f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Nikolai=20Maas=C3=B8=20Lunde?= Date: Wed, 22 Jul 2020 14:34:03 +0200 Subject: [PATCH 03/38] Norwegian language Added top 200 words in the Norwegian language. --- public/js/words.js | 203 +++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 203 insertions(+) diff --git a/public/js/words.js b/public/js/words.js index 386c09326..5963c8bc0 100644 --- a/public/js/words.js +++ b/public/js/words.js @@ -4346,4 +4346,207 @@ const words = { "problema", "preoccuparsi", ], + norwegian: [ + "i", + "og", + "det", + "om", + "er", + "til", + "en", + "av", + "på", + "for", + "at", + "å", + "med", + "de", + "har", + "den", + "ikke", + "et", + "om", + "fra", + "var", + "han", + "men", + "seg", + "vil", + "jeg", + "kan", + "ble", + "vil", + "skal", + "sier", + "etter", + "så", + "år", + "også", + "hun", + "dette", + "ved", + "da", + "blir", + "nå", + "ut", + "være", + "hadde", + "over", + "mot", + "eller", + "to", + "må", + "går", + "få", + "andre", + "opp", + "sin", + "når", + "du", + "bare", + "alle", + "ha", + "enn", + "mer", + "denne", + "selv", + "noe", + "mange", + "inn", + "bli", + "noen", + "vært", + "får", + "før", + "der", + "man", + "kroner", + "nye", + "dag", + "ting", + "flere", + "fikk", + "første", + "under", + "slik", + "siden", + "mye", + "dårlig", + "kommer", + "både", + "kunne", + "meg", + "mellom", + "hva", + "tre", + "her", + "store", + "mener", + "ingen", + "dem", + "oss", + "hele", + "sine", + "siste", + "gang", + "skulle", + "hans", + "ta", + "helt", + "godt", + "sammen", + "sa", + "kom", + "håper", + "hvor", + "nok", + "hjemme", + "alt", + "blant", + "tid", + "sitt", + "ville", + "uten", + "blitt", + "igjen", + "tidligere", + "fått", + "rundt", + "ny", + "samme", + "mens", + "annet", + "gjennom", + "disse", + "litt", + "stor", + "står", + "gjør", + "gå", + "ser", + "gjøre", + "gikk", + "folk", + "ned", + "ham", + "se", + "hvis", + "derfor", + "gamle", + "fire", + "fordi", + "mest", + "god", + "tar", + "tilbake", + "gir", + "barn", + "like", + "neste", + "gi", + "kanskje", + "langt", + "tatt", + "del", + "bedre", + "komme", + "saken", + "ønsker", + "tror", + "viser", + "først", + "måtte", + "aldri", + "side", + "ligger", + "si", + "min", + "hvordan", + "hos", + "tok", + "bør", + "beste", + "vår", + "grunn", + "hver", + "sett", + "vel", + "gjort", + "land", + "allerede", + "frem", + "heller", + "gode", + "vet", + "jo", + "tiden", + "begge", + "finnes", + "foto", + "fram", + "plass", + "mennesker", + "gjorde", + "mine", + ] }; From 845f4c12fe4dbf07d18c8c64535f770b5ca707ba Mon Sep 17 00:00:00 2001 From: Jack Date: Wed, 22 Jul 2020 18:15:22 +0100 Subject: [PATCH 04/38] extra cache clear to be safe --- public/index.html | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/public/index.html b/public/index.html index 652622efe..ba56efe25 100644 --- a/public/index.html +++ b/public/index.html @@ -7,7 +7,7 @@ Monkey Type - + @@ -1353,17 +1353,17 @@ - + - - - - - - - - - + + + + + + + + + \ No newline at end of file From 47415c6640790dfef618635efd1570797720c2bd Mon Sep 17 00:00:00 2001 From: Jack Date: Wed, 22 Jul 2020 18:29:55 +0100 Subject: [PATCH 05/38] added prespacegate log --- public/index.html | 22 +++++++++++----------- public/js/script.js | 5 +++++ 2 files changed, 16 insertions(+), 11 deletions(-) diff --git a/public/index.html b/public/index.html index ba56efe25..bf7fabcc1 100644 --- a/public/index.html +++ b/public/index.html @@ -7,7 +7,7 @@ Monkey Type - + @@ -1353,17 +1353,17 @@ - + - - - - - - - - - + + + + + + + + + \ No newline at end of file diff --git a/public/js/script.js b/public/js/script.js index fe9efab5c..53dc6eefa 100644 --- a/public/js/script.js +++ b/public/js/script.js @@ -949,6 +949,11 @@ function calculateStats() { let wpm = roundTo2( ((chars.correctWordChars + chars.correctSpaces) * (60 / testSeconds)) / 5 ); + console.log( + `pre-spacegate ${roundTo2( + ((chars.correctWordChars + chars.spaces) * (60 / testSeconds)) / 5 + )} (current ${wpm})` + ); let wpmraw = roundTo2( ((chars.allCorrectChars + chars.spaces + From bf3064e750bac9160c09def504ca638ae43f30b1 Mon Sep 17 00:00:00 2001 From: Jack Date: Wed, 22 Jul 2020 21:03:52 +0100 Subject: [PATCH 06/38] added menthol. thanks octa --- public/themes/list.json | 5 +++++ public/themes/menthol.css | 11 +++++++++++ 2 files changed, 16 insertions(+) create mode 100644 public/themes/menthol.css diff --git a/public/themes/list.json b/public/themes/list.json index ff2eabfb9..60928df86 100644 --- a/public/themes/list.json +++ b/public/themes/list.json @@ -302,5 +302,10 @@ "name": "watermelon", "bgColor": "#1F4437", "textColor": "#B74B53" + }, + { + "name": "menthol", + "bgColor": "#00c18c", + "textColor": "#ffffff" } ] \ No newline at end of file diff --git a/public/themes/menthol.css b/public/themes/menthol.css new file mode 100644 index 000000000..52dbb55b6 --- /dev/null +++ b/public/themes/menthol.css @@ -0,0 +1,11 @@ +:root { + --bg-color: #00c18c; + --main-color: #ffffff; + --caret-color: #99fdd8; + --sub-color: #186544; + --text-color: #ffffff; + --error-color: #e03c3c; + --error-extra-color: #b12525; + --colorful-error-color: #e03c3c; + --colorful-error-extra-color: #b12525; +} \ No newline at end of file From c556abf1ca13c011832db8af4fd51c6c6e80ffae Mon Sep 17 00:00:00 2001 From: Jack Date: Wed, 22 Jul 2020 21:23:25 +0100 Subject: [PATCH 07/38] made sure all _ are replaced --- public/js/commandline.js | 6 +++--- public/js/script.js | 4 ++-- public/js/settings.js | 2 +- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/public/js/commandline.js b/public/js/commandline.js index 895fd124c..ee2b6e0af 100644 --- a/public/js/commandline.js +++ b/public/js/commandline.js @@ -603,7 +603,7 @@ $.getJSON("themes/list.json", function (data) { data.forEach((theme) => { commandsThemes.list.push({ id: "changeTheme" + capitalizeFirstLetter(theme.name), - display: theme.name.replace("_", " "), + display: theme.name.replace(/_/g, " "), hover: () => { previewTheme(theme.name); }, @@ -640,7 +640,7 @@ if (Object.keys(words).length > 0) { if (language === "english_10k") return; commandsLanguages.list.push({ id: "changeLanguage" + capitalizeFirstLetter(language), - display: language.replace("_", " "), + display: language.replace(/_/g, " "), exec: () => { changeLanguage(language); restartTest(); @@ -676,7 +676,7 @@ if (Object.keys(layouts).length > 0) { Object.keys(layouts).forEach((layout) => { commandsLayouts.list.push({ id: "changeLayout" + capitalizeFirstLetter(layout), - display: layout.replace("_", " "), + display: layout.replace(/_/g, " "), exec: () => { changeLayout(layout); restartTest(); diff --git a/public/js/script.js b/public/js/script.js index 53dc6eefa..f9954df72 100644 --- a/public/js/script.js +++ b/public/js/script.js @@ -1424,7 +1424,7 @@ function showResult(difficultyFailed = false) { testType += " " + config.words; } if (config.mode != "custom") { - testType += "
" + config.language.replace("_", " "); + testType += "
" + config.language.replace(/_/g, " "); } if (config.punctuation) { testType += "
punctuation"; @@ -1554,7 +1554,7 @@ function restartTest(withSameWordset = false) { if (resultVisible) { if (config.randomTheme) { randomiseTheme(); - showNotification(config.theme.replace("_", " "), 1500); + showNotification(config.theme.replace(/_/g, " "), 1500); } $("#words").stop(true, true).animate( { diff --git a/public/js/settings.js b/public/js/settings.js index 7aa6634cc..6da64fbaa 100644 --- a/public/js/settings.js +++ b/public/js/settings.js @@ -4,7 +4,7 @@ function updateSettingsPage() { themesEl.append( `
${theme.name.replace("_", " ")}
` + };background:${theme.bgColor}">${theme.name.replace(/_/g, " ")}` ); }); From a8b9fc0ef8f5229d7b39fb8a1fa3a1ac75e48dca Mon Sep 17 00:00:00 2001 From: Jack Date: Wed, 22 Jul 2020 21:23:33 +0100 Subject: [PATCH 08/38] added round round baby --- public/js/userconfig.js | 2 +- public/themes/list.json | 5 +++++ public/themes/round_round_baby.css | 31 ++++++++++++++++++++++++++++++ 3 files changed, 37 insertions(+), 1 deletion(-) create mode 100644 public/themes/round_round_baby.css diff --git a/public/js/userconfig.js b/public/js/userconfig.js index 005e1134d..a0cb64ec6 100644 --- a/public/js/userconfig.js +++ b/public/js/userconfig.js @@ -553,7 +553,7 @@ function setTheme(name, nosave) { function randomiseTheme() { var randomList = themesList.filter(function (theme) { - return theme.name != "nausea"; + return theme.name != "nausea" && theme.name != "round_round_baby"; }); let randomtheme = randomList[Math.floor(Math.random() * randomList.length)]; setTheme(randomtheme.name, true); diff --git a/public/themes/list.json b/public/themes/list.json index 60928df86..d71285904 100644 --- a/public/themes/list.json +++ b/public/themes/list.json @@ -43,6 +43,11 @@ "bgColor": "#323437", "textColor": "#e2b714" }, + { + "name": "round_round_baby", + "bgColor": "#323437", + "textColor": "#e2b714" + }, { "name": "bushido", "bgColor": "#414755", diff --git a/public/themes/round_round_baby.css b/public/themes/round_round_baby.css new file mode 100644 index 000000000..8a14d710e --- /dev/null +++ b/public/themes/round_round_baby.css @@ -0,0 +1,31 @@ +:root { + --bg-color: #323437; + --main-color: #e2b714; + --caret-color: #e2b714; + --sub-color: #646669; + --text-color: #d1d0c5; + --error-color: #ca4754; + --error-extra-color: #7e2a33; + --colorful-error-color: #ca4754; + --colorful-error-extra-color: #7e2a33; +} + + +@keyframes woah { + 0% { + transform: rotateZ(0deg); + } + + 50% { + transform: rotateZ(180deg); + } + + 100% { + transform: rotateZ(360deg); + } +} + + +#middle { + animation: woah 5s infinite linear; +} \ No newline at end of file From fad7701f596f2e7904b2f477de3c6cc8c0436eb3 Mon Sep 17 00:00:00 2001 From: Jack Date: Wed, 22 Jul 2020 21:24:15 +0100 Subject: [PATCH 09/38] fixed overflow --- public/themes/round_round_baby.css | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/public/themes/round_round_baby.css b/public/themes/round_round_baby.css index 8a14d710e..de2c7055b 100644 --- a/public/themes/round_round_baby.css +++ b/public/themes/round_round_baby.css @@ -28,4 +28,8 @@ #middle { animation: woah 5s infinite linear; +} + +body { + overflow: hidden; } \ No newline at end of file From b101400152906a0e31731017f0806c7d0c82349d Mon Sep 17 00:00:00 2001 From: Jack Date: Wed, 22 Jul 2020 23:27:16 +0100 Subject: [PATCH 10/38] comment --- functions/index.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/functions/index.js b/functions/index.js index 7328a12fc..8afcd1e4b 100644 --- a/functions/index.js +++ b/functions/index.js @@ -1105,9 +1105,11 @@ async function checkLeaderboards( verified, emailVerified ) { + //lb disable // return { // insertedAt: null, // }; + // try { if (emailVerified === false) return { From 69f2aca703940f5f46398c560e26964f5a92e9f1 Mon Sep 17 00:00:00 2001 From: wRadion Date: Thu, 23 Jul 2020 11:21:50 +0200 Subject: [PATCH 11/38] Updated Restart Shortcut text Remove "space" as a key to restart test --- public/index.html | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/public/index.html b/public/index.html index bf7fabcc1..f570c2df1 100644 --- a/public/index.html +++ b/public/index.html @@ -1315,7 +1315,7 @@
- tab and enter / space - restart test
+ tab and enter - restart test
esc - command line
@@ -1366,4 +1366,4 @@ - \ No newline at end of file + From a5f35807afd5d9ee79966f1381ee57be96433e95 Mon Sep 17 00:00:00 2001 From: Jack Date: Thu, 23 Jul 2020 13:42:16 +0100 Subject: [PATCH 12/38] added caps lock indicator --- public/css/style.scss | 20 ++++++++++++++++++++ public/index.html | 5 ++++- public/js/script.js | 21 +++++++++++++++++++++ 3 files changed, 45 insertions(+), 1 deletion(-) diff --git a/public/css/style.scss b/public/css/style.scss index 50c690d26..21c54d4bf 100644 --- a/public/css/style.scss +++ b/public/css/style.scss @@ -1142,6 +1142,26 @@ key { } } +#capsWarning { + background: var(--main-color); + color: var(--bg-color); + display: table; + position: absolute; + left: 50%; + top: 50%; + transform: translateX(-50%) translateY(-50%); + padding: 1rem; + border-radius: var(--roundness); + /* margin-top: 1rem; */ + transition: .25s; + z-index: 999; + pointer-events: none; + + i { + margin-right: .5rem; + } +} + #wordsInput { height: 0; diff --git a/public/index.html b/public/index.html index f570c2df1..30ba5913b 100644 --- a/public/index.html +++ b/public/index.html @@ -535,6 +535,9 @@
+