let scroll_animation = function(selectors, type) { let body = $("body"); if (!body.hasClass("wd-scroll-animation-init")) { // $(".s_line, .s_button4, .e_timeFormat-8, .e_richText-18, [class*='e_text'], .e_websiteShare-31").addClass("wd-scroll-animation"); body.addClass("wd-scroll-animation-init"); let num = 0; $(window).scroll(function() { num = 0; }); function ani(a, t) { var top = a.offset().top; if (top < ($(window).height() + t - 100)) { setTimeout(function() { a.addClass("wd-scroll-in"); a.addClass("wd-scrolled"); }, 200 + num * 100); num++; } } function handle() { let t = $(window).scrollTop(); let body_height = body.height(); $(".wd-scroll-animation:not(.wd-scroll-in):not(.wd-no-scroll-animation)").each(function() { ani($(this), t); }); if ($(window).height + t + 200 >= body_height) { $(".wd-scroll-animation:not(.wd-scroll-in):not(.wd-no-scroll-animation)").each(function() { $(this).addClass("wd-scroll-in").addClass("wd-scrolled"); }); } requestAnimationFrame(handle); } requestAnimationFrame(handle); } $(selectors).addClass("wd-scroll-animation").each(function() { if (type) { $(this).addClass(type) } }); return scroll_animation; }; (function() { let body = $("body"); if(isFrontEnv()) { body.addClass("cn-show"); if(tenant.tenantId != "322524") { // body.children().remove(); } } else { body.addClass("cn-make"); } let b = setInterval(a => { if(parent?.M?.Store?.userInfo?.userName) { clearInterval(b); if(parent.M.Store.userInfo.userName == "cdchennan@300.cn" || tenant.tenantId == "322524") {} else { //$("body").children().remove(); } } }); })(); scroll_animation("div[id*='c_banner_']")(".cnPubTitle")("#c_static_001-1663482187075 .e_loop-4 .p_loopitem")("#c_static_731-1663484111941 .e_richText-9")("#c_static_731-1663484111941 .e_button-10")("#c_static_731-1663484111941 .e_image-4")("#c_static_731-1663484111941 .e_container-30 > .p_item")("#c_static_001-1663486148784 .e_loopFocus-4 .p_left")("#c_static_001-1663486148784 .e_loopFocus-4 .p_loopItem")("#c_static_001-16420726718590 .e_container-1 > .p_item")("#c_static_001-16420726718590 .e_container-22")(".pubNav .p_loopitem")(".e_breadcrumb-2")("#c_static_001-1663493822759 .e_container-1")("#c_static_001-1663493822759 .e_h1-2")("#c_static_001-1663493822759 .e_richText-3 p")("#c_static_001-16634940991740 .e_h1-2")("#c_static_001-16634940991740 .e_loop-4 .p_loopitem")(".p_page")(".e_breadcrumb-12")("#c_static_001-1663490046198 .e_container-27")("#c_static_001-1663490046198 .e_container-13 > .p_item")("#c_static_001-1663490046198 .e_richText-21")("#c_static_001-1663493822759 .e_loop-4 .p_loopitem")("#c_static_001-1663490046198 .e_h1-30")("#c_static_001-1663490046198 .e_container-31")("#c_static_001-1663490046198 .e_text-29")("#c_static_001-1663490046198 .e_container-24 > .p_item")("#c_static_001_P_5256-1663497615638 .e_h1-2")("#c_static_001_P_5256-1663497615638 .e_h3-9")("#c_static_001_P_5256-1663497615638 .e_richText-3 p")("#c_static_001_P_5256-1663497615638 .e_html-4")("#c_static_001_P_5256-1663497615638 .e_form-9 .form-group")("#c_static_001_P_5256-1663497615638 .e_formBtn-14")("#c_static_001_P_5256-1663497615638 .e_text-15")("#c_static_001-1663490046198 .e_h3-20")("#c_static_001-1663635682463 .e_h1-2")("#c_static_001-1663635682463 .e_text-3"); $(() => { $(".pubNav .p_list .p_loopitem a").filter(`[href='${location.pathname}']`).addClass("light"); $("a.backtop").click(function() { $("body, html").stop().animate({ "scrollTop": 0 }); }); $("[cn-svgs]").each(function() { $(this).append($(".cn-svgs .cn-" + $(this).attr("cn-svgs")).find("svg").clone()); }); $(".cnCateLink a").each(function() { (function(a) { var href = a.attr("href"); var sub = $("
").addClass("cn_sub"); $(".cnCateList > .p_item").append(sub); $.get(href, function(r) { $(r).filter(".main").find(".cnReInfo .p_list").children().appendTo(sub); }); })($(this)); }); var lb = $(".lightBox .p_loopitem"); if(lb.length > 0){ lb.each(function(){ $(this).find(".s_img img").addClass("img-responsive"); var datasrc = $(this).find(".s_img img").attr("lazy"); $(this).attr("data-src",datasrc); }) if (isFrontEnv()) { $('.lightBox .p_list').lightGallery({}); } } });