mirror of
https://github.com/monkeytypegame/monkeytype.git
synced 2025-12-18 22:19:05 +08:00
fix(indicate typos): input sometimes being blocked in the middle of a word
This commit is contained in:
parent
9e7740a330
commit
8d15d6b181
1 changed files with 4 additions and 1 deletions
|
|
@ -729,10 +729,13 @@ function handleChar(
|
|||
|
||||
const newActiveTop = activeWord?.offsetTop;
|
||||
//stop the word jump by slicing off the last character, update word again
|
||||
// dont do it in replace typos, because it might trigger in the middle of a wrd
|
||||
// when using non monospace fonts
|
||||
if (
|
||||
activeWordTopBeforeJump < newActiveTop &&
|
||||
!TestUI.lineTransition &&
|
||||
TestInput.input.current.length > 1
|
||||
TestInput.input.current.length > 1 &&
|
||||
Config.indicateTypos !== "replace"
|
||||
) {
|
||||
if (Config.mode === "zen") {
|
||||
if (!Config.showAllLines) void TestUI.lineJump(activeWordTopBeforeJump);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue