New bootbox renders all the buttons backwards. :<

This commit is contained in:
Neil Lalonde 2013-06-24 15:29:58 -04:00
parent c79ab3fc2e
commit e12dff2c31
2 changed files with 9 additions and 9 deletions

View File

@ -59,11 +59,9 @@ Discourse.ComposerController = Discourse.Controller.extend({
message = Em.String.i18n("composer.posting_not_on_topic", {title: this.get('content.topic.title')});
buttons = [{
"label": Em.String.i18n("composer.reply_original") + "<br/><div class='topic-title'>" + this.get('content.topic.title') + "</div>",
"class": "btn-primary btn-reply-on-original",
"callback": function(){
_this.save(true);
}
"label": Em.String.i18n("composer.cancel"),
"class": "cancel",
"link": true
}];
if(topic) {
@ -79,9 +77,11 @@ Discourse.ComposerController = Discourse.Controller.extend({
}
buttons.push({
"label": Em.String.i18n("composer.cancel"),
"class": "cancel",
"link": true
"label": Em.String.i18n("composer.reply_original") + "<br/><div class='topic-title'>" + this.get('content.topic.title') + "</div>",
"class": "btn-primary btn-reply-on-original",
"callback": function(){
_this.save(true);
}
});
bootbox.dialog(message, buttons, {"classes": "reply-where-modal"});

View File

@ -350,7 +350,7 @@ var bootbox = window.bootbox || (function(document, $) {
href = _defaultHref;
}
buttons = "<a data-handler='"+i+"' class='"+_class+"' href='" + href + "'>"+icon+""+label+"</a>" + buttons;
buttons = buttons + "<a data-handler='"+i+"' class='"+_class+"' href='" + href + "'>"+icon+""+label+"</a>";
callbacks[i] = callback;
}