This commit is contained in:
rulingcom 2022-08-24 19:50:27 +08:00
parent dd72708b34
commit 3ad9b26c9a
1 changed files with 21 additions and 9 deletions

View File

@ -748,17 +748,29 @@ function transdate(){
}
$(document).on('focusin','*',function(event){
// event.stopPropagation();
if(window.focus_timeout_id){
window.clearTimeout(window.focus_timeout_id);
}
var _this = $(document.activeElement);//$(this);
if(!_this.hasClass('close-screen-btn')){
var topOffset = window.temp_scrollY + window.top_barrier_height;
var ele_offset = _this.offset().top - topOffset;
if(ele_offset < 0){
window.scroll(window.temp_scrollX, window.temp_scrollY + ele_offset);
window.temp_scrollY = Math.max(window.temp_scrollY + ele_offset, 0);
}
window.focus_timeout_id = window.setTimeout(function(){
var ele_offset = _this.offset().top - topOffset;
if(ele_offset < 0){
window.scroll(window.temp_scrollX, window.temp_scrollY + ele_offset);
window.temp_scrollY = Math.max(window.temp_scrollY + ele_offset, 0);
}
}, 800);
if ($('header>.kenjohn').attr('class') == "kenjohn" && _this.is('a.orbit-bar-logo')){
$('header>.kenjohn').addClass('navRel');
$('#gotocenter').focus();
}
}
});
$('.group').each(function(){
if ($(this).text().trim()==''){