refactor: Move the content of HistoryCommand._hcmd_undo to BaseCli.history_undo_transaction.
refactor: Rename Base.history_undo to Base.history_undo_items_states.