Nice style, and I appreciate that I can hit Esc to dismiss most of the dialogs, though unfortunately not all of them.
As another commenter said, I do wish that clicking outside of it had the same effect, but that may have more to do with what sites typically abuse these kinds of boxes for ("Alert! Sign up to our..." (no go away)).
One issue I noticed: there's a race condition in the second-to-last example ('...and by passing a parameter, you can execute something else for "Cancel".'), where if you hit escape quickly enough as the box gets launched, the cancellation handler does not run.
As another commenter said, I do wish that clicking outside of it had the same effect, but that may have more to do with what sites typically abuse these kinds of boxes for ("Alert! Sign up to our..." (no go away)).
One issue I noticed: there's a race condition in the second-to-last example ('...and by passing a parameter, you can execute something else for "Cancel".'), where if you hit escape quickly enough as the box gets launched, the cancellation handler does not run.