Yes, the above scenario definitely leads to deadlock. Let me explain how,
Your implementation,
textareaA -> onTextChanged -> set some value to textareaB
textareaB -> onTextChanged -> set some value to textareaA
Now, you make a change to any of the text boxes. For now say, textareaA it changes value in textareaB, which in-turn changes the value in textareaA, which in-turns change value of textareaB.... and so the loop goes on.
Possible solution is to check for the focused textbox.
That is,
textareaA -> onTextChanged -> set some value to textareaB, only if textareaB is not focused
textareaB -> onTextChanged -> set some value to textareaA, only if textareaA is not focused
Doing so should help you. Hope this helps.