js: add flag to disable header image animation (#19185)
This commit is contained in:
parent
d1d6ad4694
commit
a3374a5841
|
@ -347,9 +347,11 @@ var gadjo_js = gadjo_js || {};
|
|||
if ($('#sidepage').length == 1) {
|
||||
$('body').attr('data-has-sidebar', 'true');
|
||||
}
|
||||
/* 440 is header image height (500px) - header height (60px) */
|
||||
var timestamp = ((new Date().getTime() / 1000) % 86400 ) / (86400 / 440);
|
||||
$('div#header').css('background-position', '0 -' + timestamp + 'px');
|
||||
if ($('body[data-no-moving-header]').length == 0) {
|
||||
/* 440 is header image height (500px) - header height (60px) */
|
||||
var timestamp = ((new Date().getTime() / 1000) % 86400 ) / (86400 / 440);
|
||||
$('div#header').css('background-position', '0 -' + timestamp + 'px');
|
||||
}
|
||||
|
||||
/* add × to close notification messages */
|
||||
$('.messages > li').each(function(idx, elem) {
|
||||
|
|
Loading…
Reference in New Issue