Pergola builds the pergola.notification system dialog as an alternative to the system alert(). It's preemptive, but doesn't stop the execution of the script.
To use the notification dialog you simply invoke the pergola.message() function (shortcut
$M) passing a string. The second parameter is optional and specifies the dialog's position.