moved update words height before update active element

moved update caret position outside the words height function
closes #4064
This commit is contained in:
Miodec 2023-03-13 13:55:31 +01:00
parent 3e233d9bd9
commit 07ef4fe243

View file

@ -197,8 +197,9 @@ export function showWords(): void {
$("#words").html(wordsHTML);
updateActiveElement(undefined, true);
updateWordsHeight(true);
updateActiveElement(undefined, true);
Caret.updatePosition();
updateWordsInputPosition(true);
}
@ -348,8 +349,6 @@ function updateWordsHeight(force = false): void {
if (Config.mode === "zen") {
$(<Element>document.querySelector(".word")).remove();
}
Caret.updatePosition();
}
export function addWord(word: string): void {