PageSourceSearch

https://www.verdantleisure.co.uk/assets/DurationFilter.js

js verdantleisure.co.uk collected 2026-09-26 13:38:00 UTC 1,275 bytes, 1 lines download raw bytes

1function S(a){this.el=a,this.elsSourceSelect=null,this.elTargetSelect=null,this.elsTargetSelectOptions=null,this.init=()=>{this.elsSourceSelect=this.el.querySelector("select"),!(this.elsSourceSelect.length<1)&&(this.el.dataset.target&&(this.elTargetSelect=document.querySelector(this.el.dataset.target)),this.elTargetSelect&&(this.elsTargetSelectOptions=this.elTargetSelect.querySelectorAll("option"),!(this.elsTargetSelectOptions.length<1)&&(r(),n())))};const r=()=>{i(this.elsSourceSelect.options[this.elsSourceSelect.selectedIndex].classList)},n=()=>{this.elsSourceSelect.addEventListener("change",t=>{window.namespace.datePrices=null,i(t.target.options[t.target.selectedIndex].classList)})},i=t=>{let c=Array.from(t);const o=this.elTargetSelect.value;this.elTargetSelect.innerHTML="";const l=[...this.elsTargetSelectOptions];l[0].disabled&&!l[0].value&&this.elTargetSelect.append(l[0]),l.forEach(e=>{if(c.length==0||c.some(s=>e.classList.contains(s))){let s=document.querySelector('[name="BookingProductTypeId"]:checked');s?s.value==1?e.classList.contains("duration--accommodation")&&this.elTargetSelect.append(e):e.classList.contains("duration--touring")&&this.elTargetSelect.append(e):this.elTargetSelect.append(e)}}),this.elTargetSelect.value=o}}export{S as default};

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.