Nikku/jquery-bootstrap-scripting — Issue #29: Improvements on helpers
Author: Jito
Created: 2012-02-24 22:10:07+00:00
State: open

It'd be nice if we can pass extra arguments to `alert`, `prompt` and `confirm` helpers, like custom title and content, the same way you can set callback fns.
And maybe give the buttons a special class (like for the primary action) and caption (for internationalization purposes, without having to mess up with the source code of the plugin).

Something like this, perhaps:

```javascript
$("#show-confirm").click(function() {
$.fn.dialog2.helpers.confirm({
title: 'Will you do it?',
message: 'How could you resist with such a fancy confirmation?',
confirm: {
label: '¡Claro que si, amigo!',
btnClass: 'success',
callback: function() { alert("You said yes!"); }
},
decline: function() { alert("You said no!") }
});
});
```

What do you think?