onCancel param added

As a prompt replacement I needed the cancel button to also trigger an action.

I see that my editor has messed up your spacing conventions.