1import{C as c,a as h,d as a,f as v}from"./app-7rvwEe1q.js";try{let o=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},e=new o.Error().stack;e&&(o._sentryDebugIds=o._sentryDebugIds||{},o._sentryDebugIds[e]="a5146444-a45f-410a-a8a2-52f2d5bf9163",o._sentryDebugIdIdentifier="sentry-dbid-a5146444-a45f-410a-a8a2-52f2d5bf9163")}catch{}const d=class d extends c{constructor(){super(...arguments),this.hoverEls=[],this.classRemover=()=>{h(this).remove("has-hovered")}}init(){this.hover=this.$("hover"),this.hoverEls=this.$$("hover-el"),this.addEventListener("mouseleave",this.classRemover),a.on("resize",this.classRemover),v(e=>{this.hoverEls.forEach(t=>{t.addEventListener("mouseenter",()=>{this.setHover(t,e)})});let r=-1;a.on("scroll",()=>{this.hoverEls.forEach((t,s)=>{const{height:n,top:i}=t.getBoundingClientRect();i<window.innerHeight/2&&i+n>window.innerHeight/2&&r!==s&&(r=s,this.setHover(t,e))})})})}setHover(e,r){h(this.hoverEls).remove("hovered");const t=this.getBoundingClientRect().top,{height:s,top:n}=e.getBoundingClientRect(),i=e.style.getPropertyValue("--bg-color"),l=e.style.getPropertyValue("--bg-alt");h(e).add("hovered"),h(this).add("has-hovered"),i?this.style.setProperty("--bg-color",i):this.style.removeProperty("--bg-color"),l?this.style.setProperty("--bg-alt",l):this.style.removeProperty("--bg-alt"),r.to(this.hover,{y:Math.abs(t-n),height:s,duration:.5,ease:"power2.out"})}setHovers(e,r=!1){h(this).remove("has-hovered"),v(t=>{e.forEach(s=>{s.addEventListener("mouseenter",()=>{this.setHover(s,t)})}),r?this.hoverEls=e:this.hoverEls.push(...e)})}destroyed(){a.off("resize",this.classRemover)}};d.component="b-list-hover";let f=d;export{f as default}; 2//# sourceMappingURL=ListHover-oU1t3myZ.js.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.