$(function(){ // 椤甸?㈤?浜 $('[data-id=' + pageObj._detailId + ']').addClass('active'); // 榛?璁ゆ?т欢?????剧???惧ぇ???挎?广?? $(".fancyImg").each(function(){ let fancyImg = $(this).find("img").attr("src"); $(this).parents(".fancyboxHz").attr("data-src",fancyImg) }); // ???т欢?????剧???惧ぇ $('.fancyImg-02 img').each(function(){ let iText = $(this).attr('alt'); $(this).parent().append('

'+ iText +'

'); $(this).parents(".fancyboxHz").attr("data-caption",iText) }); // ==> ????缁?浠?S // ?剧???惧ぇ-02 ?鹃????? $require(['swiper'], function () { var imgTuBox = new Swiper ('.imgTuBig', { slidesPerGroup : 1, //婊??ㄤ釜? slidesPerView : 2, //?? spaceBetween : 15, //?宠竟璺? grid: { fill: 'row', rows: 1, //琛? }, pagination: { el: '.imgTuBig .swiper-pagination', clickable :true, }, navigation: { nextEl: '.imgTuBig .swiper-button-next', prevEl: '.imgTuBig .swiper-button-prev', }, breakpoints: { 768: { //褰?灞?骞?瀹藉害澶т?绛?浜?768 slidesPerView: 5, spaceBetween : 20, //?宠竟璺? }, } }) }) // ?剧???惧ぇ-03 ???板????https://www.dowebok.com/214.html*/ }) $(document).scroll(function(){ // 椤甸?㈠?涓?婊??ㄥ??娣诲????绫诲?? if(window.scrollY >= 50){ $('body > .main > div:nth-child(1)').addClass('downClass'); }else{ $('body > .main > div:nth-child(1)').removeClass('downClass'); } // ??浣跨?ㄦ?规??? // 1??浣跨?ㄦ?跺?????辫?缃??绂婚《?ㄧ??楂?搴 // 2??downClass绫诲??濡?涓?婊¤冻?????辩?杈?涓哄?朵?绫诲?? // 3???蜂?瀹??扮???峰???瑕?????版?峰???浠堕??瀹?涔?downClass????宸蹭慨?逛负?朵???绫诲???峰? });