PageSourceSearch

https://www.labello.com/dist/NiveaX/modules/ScrollSlider.4b114057.js

js labello.com collected 2026-10-02 12:43:01 UTC 2,670 bytes, 2 lines download raw bytes

1"use strict";(self.NiveaXwebpackJsonp=self.NiveaXwebpackJsonp||[]).push([[7755],{7769:(t,e,s)=>{s.r(e),s.d(e,{default:()=>l});var r=s(21464);const i='[data-module="ScrollSlider"]';class l{static setup(t=i){Array.from(document.querySelectorAll(t)).filter(t=>!t.dataset.moduleInitialized).forEach(t=>{new l(t),t.dataset.moduleInitialized="true"})}constructor(t,e={}){this.element=t,this.options=e,this.options=(0,r.$E)(this.element,Object.assign(this.getDefaultOptions(),this.options)),this.isRtl=null!=document.dir?"rtl"===document.dir:"rtl"==document.getElementsByTagName("html")[0].getAttribute("dir"),this.leftBtn=this.element.querySelector(this.options.arrowLeft),this.rightBtn=this.element.querySelector(this.options.arrowRight),this.scrollBarContainer=this.element.querySelector(this.options.scrollContent),this.scrollBarContainer&&this.init()}init(){document.addEventListener("ScrollSlider:reset",()=>this.showArrows()),window.addEventListener("resize",(0,r.sg)(()=>this.showArrows(),200)),this.scrollBarContainer.addEventListener("scroll",()=>this.checkArrows()),this.arrowHandlers()}arrowHandlers(){this.arrowHandlersMouseEvent(this.leftBtn,this.isRtl?50:-50),this.arrowHandlersMouseEvent(this.rightBtn,this.isRtl?-50:50)}arrowHandlersMouseEvent(t,e){t.addEventListener("click",()=>{this.scrollElement(e)},{passive:!0}),t.addEventListener("mousedown",()=>{this.setIntervalToScroll(e)},{passive:!0}),t.addEventListener("mouseup",()=>{clearInterval(this.intervalToScroll)},{passive:!0}),t.addEventListener("touchstart",()=>{this.setIntervalToScroll(e)},{passive:!0})}setIntervalToScroll(t){this.intervalToScroll&&clearInterval(this.intervalToScroll),this.intervalToScroll=setInterval(()=>this.scrollElement(t),100)}scrollElement(t){this.scrollBarContainer.scrollBy({top:0,left:t,behavior:"smooth"})}showArrows(){this.element.classList.remove("nx-scroll-slider--active"),this.scrollBarWidth=this.scrollBarContainer.offsetWidth,this.elementWidth=this.element.offsetWidth,this.scrollBarWidth>=this.elementWidth&&this.element.classList.add("nx-scroll-slider--active")}checkArrows(){0==this.scrollBarContainer.scrollLeft?this.leftBtn.classList.add("nx-arrow--hidden"):this.leftBtn.classList.remove("nx-arrow--hidden"),this.scrollBarWidth-this.elementWidth-5>=Math.abs(this.scrollBarContainer.scrollLeft)?this.rightBtn.classList.remove("nx-arrow--hidden"):this.rightBtn.classList.add("nx-arrow--hidden")}getDefaultOptions(){return{scrollContent:".nx-filter-navigation__list",arrowLeft:".nx-filter-navigation__arrow--left",arrowRight:".nx-filter-navigation__arrow--right"}}}l.setup(i)}}]);
2//# sourceMappingURL=/dist/NiveaX/./modules/ScrollSlider.4b114057.js.62424310.map

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.