mirror of
https://github.com/pgadmin-org/pgadmin4.git
synced 2025-02-25 18:55:31 -06:00
Replace bootstrap-dialog with Alertify.js, which is more configurable
and supports non-modal dialogs.
This commit is contained in:
@@ -10,7 +10,36 @@
|
||||
#}
|
||||
|
||||
function about_show() {
|
||||
BootstrapDialog.show({
|
||||
title: 'About {{ config.APP_NAME }}',
|
||||
message: $('<div></div>').load('{{ url_for('about.index') }}')});
|
||||
if (!alertify.aboutDialog) {
|
||||
alertify.dialog('aboutDialog', function factory() {
|
||||
return {
|
||||
main:function(title, message) {
|
||||
this.set('title', title);
|
||||
this.message = message;
|
||||
},
|
||||
setup:function() {
|
||||
return {
|
||||
buttons:[{ text: "OK", key: 27, className: "btn btn-primary" }],
|
||||
focus: { element: 0 },
|
||||
options: { modal: 0, overflow: false, resizable: true }
|
||||
};
|
||||
},
|
||||
build:function() {
|
||||
this.elements.body.style.minHeight = "450px";
|
||||
this.elements.body.style.minWidth = "800px";
|
||||
},
|
||||
prepare:function() {
|
||||
this.setContent(this.message);
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
var content = '';
|
||||
$.get("{{ url_for('about.index') }}",
|
||||
function(data) {
|
||||
alertify.aboutDialog('About {{ config.APP_NAME }}', data);
|
||||
}
|
||||
);
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user