add js for scrolling to error/notice
This commit is contained in:
@@ -5,10 +5,18 @@
|
|||||||
|
|
||||||
Danbooru.notice = function(msg) {
|
Danbooru.notice = function(msg) {
|
||||||
$('#notice').html(msg).addClass("ui-state-highlight").removeClass("ui-state-error").fadeIn("fast");
|
$('#notice').html(msg).addClass("ui-state-highlight").removeClass("ui-state-error").fadeIn("fast");
|
||||||
|
var scroll_top = $("#notice");
|
||||||
|
$('html, body').animate({
|
||||||
|
scrollTop: scroll_top
|
||||||
|
}, 250);
|
||||||
}
|
}
|
||||||
|
|
||||||
Danbooru.error = function(msg) {
|
Danbooru.error = function(msg) {
|
||||||
$('#notice').html(msg).removeClass("ui-state-highlight").addClass("ui-state-error").fadeIn("fast");
|
$('#notice').html(msg).removeClass("ui-state-highlight").addClass("ui-state-error").fadeIn("fast");
|
||||||
|
var scroll_top = $("#notice");
|
||||||
|
$('html, body').animate({
|
||||||
|
scrollTop: scroll_top
|
||||||
|
}, 250);
|
||||||
}
|
}
|
||||||
|
|
||||||
Danbooru.is_subset = function(array, subarray) {
|
Danbooru.is_subset = function(array, subarray) {
|
||||||
|
|||||||
Reference in New Issue
Block a user