var w001_index_header_40 = {}; // 判断是否放得下 w001_index_header_40.nav = { change(el){ if(el.hasClass('hide-active')){ $('.w001_index_header_40').addClass('pc_app') }else{ $('.w001_index_header_40').removeClass('pc_app') } } }; w001_index_header_40.search = { show(el){ ly2.popup2.show(el, '/search-popup', {}, { callback(res){ console.log(res) } }) }, }; var lyuiheader_nav_001 = {}; // 判断导航是否放得下 lyuiheader_nav_001.nav_width = { compare(el){ let nav_width = 0; let auto_width = $(el).width(); $(el).find('.lyuiheader_nav_001-li').each(function(){ nav_width += $(this).outerWidth() }) if(nav_width > auto_width || window.innerWidth < 800){ $(el).addClass('hide-active') }else{ $(el).removeClass('hide-active') } }, go(){ let _thi = this; $('.lyuiheader_nav_001').each(function(e){ _thi.compare(this); }); } }; $$My.setTime(()=>{lyuiheader_nav_001.nav_width.go()}, 10);; ; ; ; $(function(){}) $(document).ready(function(){}); ; ; ; var w004_about_us_about_284_num_bord = function(){ var el = $('#w004_about_us_about_284 .info .right .ul'); var parent = $('#w004_about_us_about_284 .info .right'); var n = 0; // 左边距 var lf = 60; // 右边距 var rt = 60; var sum = 0; var sum_wid = parent.width(); // 移出原有结构 $("#w004_about_us_about_284 .li_f").remove(); $('#w004_about_us_about_284 .info .right .ul').removeClass('no_bord_rt'); // 去除左边距 // $('#w004_about_us_about_284 .info .right .ul').removeClass('no_pd_lt'); // 左边距固定 el.each(function(i){ n++; let item = $(this); let width = item.width(); sum += width; let total = sum + (lf + rt)*(n-1) + lf; if( total > sum_wid){ item.prev().addClass('no_bord_rt') // item.addClass('no_pd_lt') if(i) item.before('
'); sum = width; n=1; } }); } $(document).ready(function(){ w004_about_us_about_284_num_bord() }) $(window).resize(function(){ w004_about_us_about_284_num_bord() });; ; $(function(){ }); ; ; ; $(document).ready(function() { const $target = $('#temp_d_mhj_other_309'); function checkScrollPosition() { const scrollTop = $(window).scrollTop(); // 当前滚动距离 const windowHeight = $(window).height(); // 视口高度 const targetOffsetTop = $target.offset().top; // 元素的顶部距离文档的距离 const targetHeight = $target.outerHeight(); // 元素的高度 const targetBottom = targetOffsetTop + targetHeight; // 目标元素底部距离文档顶部的距离 if (scrollTop + windowHeight > targetOffsetTop && scrollTop < targetBottom) { if(!$target.hasClass('cur')){ $target.addClass('cur'); } } } checkScrollPosition(); // 滚动事件 $(window).on('scroll', function() { checkScrollPosition(); }); });; ; $(function(){ }); ; ; ; $(document).on('click','#w005_index_footer_48_nav_app .dl .dt',function(){ var parent = $(this).parent(); if(!parent.find('.dd a').size()){return} if(parent.hasClass('cur')){ parent.removeClass('cur') }else{ parent.addClass('cur') } parent.find('.dd').slideToggle(500) parent.siblings().find('.dd').slideUp(500) }); ;