Commit b14b00cb authored by Rafael Ostertag's avatar Rafael Ostertag
Browse files

Alert.js: change fade effect to slide effect. Properly use slide effect, now also sliding alert in.

parent 4fecf1b0
......@@ -200,6 +200,7 @@ if (!QfqNS) {
var $alertContainer = this.makeAlertContainerSingleton();
this.$alertDiv = $("<div>")
.hide()
.addClass("alert")
.addClass(this.getAlertClassBasedOnMessageType())
.attr("role", "alert")
......@@ -216,7 +217,7 @@ if (!QfqNS) {
}
$alertContainer.append(this.$alertDiv);
this.$alertDiv.fadeIn(this.fadeInDuration, this.afterFadeIn.bind(this));
this.$alertDiv.slideDown(this.fadeInDuration, this.afterFadeIn.bind(this));
this.shown = true;
......@@ -248,7 +249,7 @@ if (!QfqNS) {
}
}
var that = this;
this.$alertDiv.fadeOut(this.fadeOutDuration, function () {
this.$alertDiv.slideUp(this.fadeOutDuration, function () {
that.$alertDiv.remove();
that.$alertDiv = null;
that.shown = false;
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment