Fix File
•
/
home
/
sportsfe...
/
httpdocs
/
wp-conte...
/
plugins
/
themify-...
/
themify
/
js
/
modules
/
swiper
/
modules
•
File:
thumbs.min.js
•
Content:
var TF_Swiper_Thumbs;(()=>{const t=t=>t.swiper?.constructor.getParentSwiper(t);TF_Swiper_Thumbs=class{constructor(t,e,s){const i={autoScrollOffset:0,multipleActiveThumbs:!0,slideThumbActiveClass:"tf_sw_thumb_active",...s.thumbs};t.classList.add(s.thumbs?.thumbsContainerClass||"tf_sw_thumbs"),delete s.thumbs;let o=t.dataset.thumbsId,n=e.dataset.thumbs;o&&n===o||(t.dataset.thumbsId=o=n||"tf_"+Math.random().toString(36).substr(2,9)),n||(e.dataset.thumbs=o),e.swiper||new TF_Swiper(e,s),i.multipleActiveThumbs&&e.swiper.params.slidesPerView>1&&(i.watchSlidesProgress=!0),new TF_Swiper(t,{...s,...i}),this.el=t,e.swiper.thumbs=this,this.t(e.swiper),e.swiper.emit("thumbs_init")}i(t,e){const s=this.el.swiper,i=s.params,o=t.target.closest("."+i.slideClass);if(o&&s.enabled&&!o.classList.contains(i.slideThumbActiveClass)){const t=i.loop?~~o.dataset.swiperSlideIndex:s.slides.indexOf(o);e.params.loop?e.slideToLoop(t):e.slideTo(t)}}t(e){const s=this,i=s.el.swiper;i?.el?(s.thumbUpdate(e,!0),s.el.tfOn("click",(e=>{const s=t(e.currentTarget);s?.thumbs?.i(e,s)}),{passive:!0}),e.on("slideChange update setTransition",(t=>{const e=t.currentTarget.swiper,s=e?.thumbs;s?.el?.isConnected?e.enabled&&s.el.swiper.enabled&&("setTransition"===t.type?s.el.swiper.setTransition(t.detail?.[0]):s.thumbUpdate(e)):s?.destroy()})).once("destroy",(t=>{t.currentTarget.swiper?.thumbs?.destroy()})),e.params.breakpoints&&e.on("breakpoint",(t=>{t.currentTarget.swiper?.once("resize",(t=>{const e=t.currentTarget.swiper;e?.thumbs?.thumbUpdate(e,!0)}))})),i.params.breakpoints&&i.on("breakpoint",(e=>{e.currentTarget.swiper?.once("resize",(e=>{const s=t(e.currentTarget);s?.thumbs?.thumbUpdate(s,!0)}))})),i.once("destroy",(e=>{t(e.currentTarget)?.thumbs?.destroy()}))):s.destroy()}destroy(){const t=this;t.el&&(t.el.swiper.destroy(),t.el?.remove(),t.el=null)}thumbUpdate(t,e){const s=this.el.swiper;if(!s?.el)return void this.destroy();const i=s.params,o=s.slides,n=!!i.loop,r=i.slideThumbActiveClass,c=t.params.slidesPerView,l=i.multipleActiveThumbs&&c>1&&!t.params.centeredSlides?c:1,h=t.realIndex,f=i.autoScrollOffset,u=f&&!n;if(t.el&&s.el&&t.enabled){for(let t=o.length-1;t>-1;--t)o[t].classList.remove(r);for(let t=l-1;t>-1;--t)if(!0===n){let e=""+(h+t);for(let t=s.wrapperEl.children,i=t.length-1;i>-1;--i)t[i].dataset.swiperSlideIndex===e&&t[i].classList.add(r)}else o[h+t]?.classList.add(r);if(h!==s.realIndex||u){let r,c,l=t.previousIndex;if(n){const e=""+h;for(let t=0;t<o.length;++t)if(o[t].dataset.swiperSlideIndex===e){r=t;break}c=t.activeIndex>l?"next":"prev"}else r=h,c=r>l?"next":"prev";if(u&&(r+="next"===c?f:-f),!s.visibleSlidesIndexes?.includes(r)){const t="auto"===i.slidesPerView?s.slidesPerViewDynamic():i.slidesPerView;if(i.centeredSlides){let e=~~(t/2);r>s.activeIndex?(e*=-1,++e):--e,r+=e}s.slideTo(r,!0===e?0:void 0)}}}}}})();
•
Search:
•
Replace:
Function
Edit by line
Download
Information
Rename
Copy
Move
Delete
Chmod
List