mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2025-06-23 03:20:54 -04:00
Add back scroll code
This commit is contained in:
parent
dae4df2a3e
commit
632b42716e
@ -198,6 +198,18 @@
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
// set timeout onDomReady
|
||||||
|
setTimeout(delayedFragmentTargetOffset, 500);
|
||||||
|
|
||||||
|
// add scroll offset to fragment target (if there is one)
|
||||||
|
function delayedFragmentTargetOffset(){
|
||||||
|
var offset = $(':target').offset();
|
||||||
|
if (offset) {
|
||||||
|
var scrollto = offset.top - 180; // minus fixed header height
|
||||||
|
$('html, body').animate({scrollTop:scrollto}, 0);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
});
|
});
|
||||||
|
|
||||||
</script>
|
</script>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user