I have a 9 rows to print, and that animation should work in loop, the first time iteration works as expected, but the 2nd and all after that, the erase leaves the first letter in the span for each line, like here in the image.
Debug Report
The error is in the typing.js at line 166, in while loop.
you set the cursor.charPos back to 0 or -1, but never set the cursor.numToErase to reset value.
So this mess up the calculation value for counting the backspace erase count.
The following shows the error present in the code, after completing the line, an going in loop instead of setting back to the 0 numToErase gets set to the count of the line to erase next.
ISSUE
I have a 9 rows to print, and that animation should work in loop, the first time iteration works as expected, but the 2nd and all after that, the erase leaves the first letter in the span for each line, like here in the image.
Debug Report
The error is in the
typing.js
at line 166, in while loop. you set thecursor.charPos
back to 0 or -1, but never set thecursor.numToErase
to reset value.So this mess up the calculation value for counting the backspace erase count. The following shows the error present in the code, after completing the line, an going in loop instead of setting back to the 0
numToErase
gets set to the count of the line to erase next.where it should have been
Solution
LlBRARY FIX Add following line bellow the line 166
IMPLEMENTATION FIX Adding +1 to the actual count of the text does temporary fix the bug