Hovering the cursor over one shows a tooltip of "Select the previously edited macro." So it's like a Back button for moving through edited macros (and there's a forward button). Click and hold on that "Back button and a list of recently edited macros will be shown, all presumably in reverse chronological order.
It's difficult to understand what took place here, but I suspect there's more to this. I've never heard of macros disappearing. Select a macro, press Delete (or Forward Delete), and... nothing will happen. Point being, there's no one-finger keyboard shortcuts for deleting macros. There's Command-Delete to remove a macro, and there's Edit > Delete, and that's why I suspect there's more that took place than you described.
Backup: Besides any general system backups you may perform, see File > Revert Macros in the Keyboard Maestro Editor.
Undo: It's in the Edit menu and also uses the standard Command-Z shortcut. Delete a macro with Command-Delete and pressing Command-Z will bring it back.