var w001_index_header_1 = {}; // 判斷是否放得下 w001_index_header_1.nav = { change(el){ if(el.hasClass('hide-active')){ $('.w001_index_header_1').addClass('pc_app') }else{ $('.w001_index_header_1').removeClass('pc_app') } } }; w001_index_header_1.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){ $(el).addClass('hide-active') }else{ $(el).removeClass('hide-active') } $(el).execFn(); }, go(){ let _thi = this; $('.lyuiheader_nav_001').each(function(e){ _thi.compare(this); }); } }; $(document).ready(function(){ lyuiheader_nav_001.nav_width.go(); }); $.taskPush('resize.lyuiheader_nav_001',function(){ lyuiheader_nav_001.nav_width.go(); });; ; ; ; $(document).click(function(e){ if ($( e.target ).closest("#w005_service_breadcrumb_208 .category_app .menu, #w005_service_breadcrumb_208 .category_app .ul").size()) { $('#w005_service_breadcrumb_208 .category_app .ul').slideToggle(500) $('#w005_service_breadcrumb_208 .category_app .menu').toggleClass('cur') } else { $('#w005_service_breadcrumb_208 .category_app .ul').slideUp(500) $('#w005_service_breadcrumb_208 .category_app .menu').removeClass('cur') } }); ; ; ; $(window).scroll(()=>{ var window_top = window.scrollY; var box_top = $('#w005_service_case_else_210').offset().top var window_h = $(window).height() var box_h = $('#w005_service_case_else_210').height() var total_h = window_h + box_h var img_h = box_h*2 var trans = Math.floor(box_top+box_h - window_top)/Math.floor(total_h) $('#w005_service_case_else_210 .bg').css('height',`${img_h}px`) if(box_top-window_h<=window_top&&window_top<=box_top+box_h){ $('#w005_service_case_else_210 .bg').css('transform',`translateY(${-trans*60}%)`) } }); ; $(document).on('click','#temp_wcb_footer_footer04_2_nav_app .dl .dt',function(){ var el = $(this); if(!el.next('.dd').find('a').size()){return} if(el.hasClass('cur')){ el.removeClass('cur') }else{ el.addClass('cur') } el.parent('.dl').find('.dd').slideToggle(500) el.parent('.dl').siblings().find('.dd').slideUp(500) }); ; 六月婷婷中文字幕_国产综合久久久久久_亚洲能在线看的黄色网站_亚洲欧美激情在线一区