Relatedly, have you ever thought about how undo works with text?
Open your mail client, compose a message, type a few words. What do you expect cmd-z to do? How much of the words will it undo? All the line? Try it.
Then after undo, type a bit more. Hit enter and cursor back. Type again.
Undoing typing is no trivial matter.