How to undo only actions (skipping all of the "undo clicking")?

I need to press the Ctrl+Z shortcut not once, but 5-10 times if I was left clicking on something (i.e. checking actor details) after the action, since UE counts left-clicking towards the list of actions. Is there a settings that can disable left clicking to count towards actions, or any other way to change Ctrl+Z behavior to undo any action except left clicking?

If this is simple and was already answered, I’m sorry, I couldn’t find an answer in Googe or searching forums.