refactor alerts to use a shared Confirm alert with two buttons and DRY up button focus code