ScrollTo tweak when selecting tasks

This commit is contained in:
2016-09-29 15:37:40 +02:00
parent 5ae33041ed
commit 48b9209d2f

View File

@@ -312,8 +312,8 @@ $(function() {
var shot_id = e.delegateTarget.dataset.shotId; var shot_id = e.delegateTarget.dataset.shotId;
shot_open(shot_id); shot_open(shot_id);
if ($(window).scrollTop() > 270) { if ($(window).scrollTop() > 100) {
$("html, body").animate({scrollTop: 0 }, '500', 'swing'); $("html, body").animate({scrollTop: 50 }, '500', 'swing');
} }
}); });
@@ -322,8 +322,8 @@ $(function() {
var task_id = e.delegateTarget.dataset.taskId; var task_id = e.delegateTarget.dataset.taskId;
task_open(task_id); task_open(task_id);
if ($(window).scrollTop() > 270) { if ($(window).scrollTop() > 100) {
$("html, body").animate({scrollTop: 0 }, '500', 'swing'); $("html, body").animate({scrollTop: 50 }, '500', 'swing');
} }
}); });
}); });