mirror of
https://github.com/monkeytypegame/monkeytype.git
synced 2024-09-20 07:16:17 +08:00
fix(caret): incorrect placement in tape mode: word
This commit is contained in:
parent
feaff239f2
commit
b22e0a407d
|
@ -150,7 +150,10 @@ export async function updatePosition(noAnim = false): Promise<void> {
|
|||
const wordsWrapperWidth =
|
||||
$(document.querySelector("#wordsWrapper") as HTMLElement).width() ?? 0;
|
||||
|
||||
if (Config.tapeMode === "letter") {
|
||||
if (
|
||||
Config.tapeMode === "letter" ||
|
||||
(Config.tapeMode === "word" && inputLen === 0)
|
||||
) {
|
||||
newLeft = wordsWrapperWidth / 2 - (fullWidthCaret ? 0 : caretWidth / 2);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue