Some characters, such as accented letters, can be stored in more than one way, and Claude Code converts them to a single standard form called NFC. That conversion can change the length of the text. When text in the prompt input is replaced, the cursor position is now measured on the converted text. If the cursor would land in the middle of a single visible character, it moves to the end of that character.
Why
Editing text that contains accented letters, emoji or other combined characters no longer leaves the cursor somewhere it can split a character.