jquery-confirm
jquery-confirm copied to clipboard
Inconstant behavior
jquery-confirm version: v3.3.0
I'm submitting a ... (check one with "x") [x ] bug report [ ] feature request [ ] support request
Current behavior:
Confirm message with animation 'top' is opened and flys in from top. A value selected. Modal closes and a bootstrap dialog is opened showing the result. Dialog is closed. Confirm message is opened again and the animation setting (top) is not honored. Flyin comes from top/left
Expected behavior:
Regardless of opening a dialog from a different, top animation is honored.
Steps to reproduce: Confirm message with animation 'top' is opened and flys in from top. A value selected. Modal closes and a dialog is shown using bootstrap. Confirm message is opened and the animation setting is not honored. Flyin comes from top/left
Related code: Bootstrap Dialog: (Layout)
<div id="errormessage" class="modal fade" role="dialog" aria-hidden="true" data-backdrop="static">
<div class="modal-dialog">
<div class="modal-content">
<div class="modal-header">
<h3 id="errormessageTitle"></h3>
</div>
<div class="modal-body">
<p id="errormessageContent"></p>
</div>
<div class="modal-footer">
<button type="button" class="btn btn-primary" data-dismiss="modal" data-target="#errormessage">Close</button>
</div>
</div>
</div>
</div>
(JS)
var ErrorMessage = {
show: function (message, title) {
var selector = 'errormessage';
var elem = null;
$('#errormessageTitle').html(title || "Error:");
$('#errormessageContent').html(message || "");
$('#' + selector).modal();
}
};
Jquery Confirm:
var Confirm = function (message, title, callback) {
$.confirm({
animation: 'top',
title: title,
content: message,
buttons: {
confirm: {
btnClass: 'btn-primary',
action: function() {
callback(true);
}
},
cancel: function () {
callback(false);
}
}
});
};
Other information: Jquery Version: 3.3.1 Jquery Confirm Version: v3.3.0 Bootstrap Version: 4.1.2 Using unaltered style sheets
I have this issue with a $.dialog as well, also 3.3.0. I implemented it in a navbar. When open, it always flies in from the top left hand corner, regardless of whether animation param was set. closeAnimation works okay
Same here! with 3.3.4