PageSourceSearch

https://www.delaval.com/assets/scroll-Cogdr4vM.js

js delaval.com collected 2026-10-02 03:34:33 UTC 5,678 bytes, 1 lines download raw bytes

1import{a as e,t}from"./rolldown-runtime-B0Z9INg1.js";var n=t(((e,t)=>{(function(n,r){typeof define==`function`&&define.amd?define([],(function(){return r(n)})):typeof e==`object`?t.exports=r(n):n.SmoothScroll=r(n)})(typeof global<`u`?global:typeof window<`u`?window:e,(function(e){var t={ignore:`[data-scroll-ignore]`,header:null,topOnEmptyHash:!0,speed:500,speedAsDuration:!1,durationMax:null,durationMin:null,clip:!0,offset:0,easing:`easeInOutCubic`,customEasing:null,updateURL:!0,popstate:!0,emitEvents:!0},n=function(){return`querySelector`in document&&`addEventListener`in e&&`requestAnimationFrame`in e&&`closest`in e.Element.prototype},r=function(){var e={};return Array.prototype.forEach.call(arguments,(function(t){for(var n in t){if(!t.hasOwnProperty(n))return;e[n]=t[n]}})),e},i=function(t){return!!(`matchMedia`in e&&e.matchMedia(`(prefers-reduced-motion)`).matches)},a=function(t){return parseInt(e.getComputedStyle(t).height,10)},o=function(e){var t;try{t=decodeURIComponent(e)}catch{t=e}return t},s=function(e){e.charAt(0)===`#`&&(e=e.substr(1));for(var t=String(e),n=t.length,r=-1,i,a=``,o=t.charCodeAt(0);++r<n;){if(i=t.charCodeAt(r),i===0)throw new InvalidCharacterError(`Invalid character: the input contains U+0000.`);if(i>=1&&i<=31||i==127||r===0&&i>=48&&i<=57||r===1&&i>=48&&i<=57&&o===45){a+=`\\`+i.toString(16)+` `;continue}if(i>=128||i===45||i===95||i>=48&&i<=57||i>=65&&i<=90||i>=97&&i<=122){a+=t.charAt(r);continue}a+=`\\`+t.charAt(r)}var s;try{s=decodeURIComponent(`#`+a)}catch{s=`#`+a}return s},c=function(e,t){var n;return e.easing===`easeInQuad`&&(n=t*t),e.easing===`easeOutQuad`&&(n=t*(2-t)),e.easing===`easeInOutQuad`&&(n=t<.5?2*t*t:-1+(4-2*t)*t),e.easing===`easeInCubic`&&(n=t*t*t),e.easing===`easeOutCubic`&&(n=--t*t*t+1),e.easing===`easeInOutCubic`&&(n=t<.5?4*t*t*t:(t-1)*(2*t-2)*(2*t-2)+1),e.easing===`easeInQuart`&&(n=t*t*t*t),e.easing===`easeOutQuart`&&(n=1- --t*t*t*t),e.easing===`easeInOutQuart`&&(n=t<.5?8*t*t*t*t:1-8*--t*t*t*t),e.easing===`easeInQuint`&&(n=t*t*t*t*t),e.easing===`easeOutQuint`&&(n=1+--t*t*t*t*t),e.easing===`easeInOutQuint`&&(n=t<.5?16*t*t*t*t*t:1+16*--t*t*t*t*t),e.customEasing&&(n=e.customEasing(t)),n||t},l=function(){return Math.max(document.body.scrollHeight,document.documentElement.scrollHeight,document.body.offsetHeight,document.documentElement.offsetHeight,document.body.clientHeight,document.documentElement.clientHeight)},u=function(t,n,r,i){var a=0;if(t.offsetParent)do a+=t.offsetTop,t=t.offsetParent;while(t);return a=Math.max(a-n-r,0),i&&(a=Math.min(a,l()-e.innerHeight)),a},d=function(e){return e?a(e)+e.offsetTop:0},f=function(e,t){var n=t.speedAsDuration?t.speed:Math.abs(e/1e3*t.speed);return t.durationMax&&n>t.durationMax?t.durationMax:t.durationMin&&n<t.durationMin?t.durationMin:n},p=function(e,t,n){t||!history.pushState||!n.updateURL||history.pushState({smoothScroll:JSON.stringify(n),anchor:e.id},document.title,e===document.documentElement?`#top`:`#`+e.id)},m=function(t,n,r){t===0&&document.body.focus(),!r&&(t.focus(),document.activeElement!==t&&(t.setAttribute(`tabindex`,`-1`),t.focus(),t.style.outline=`none`),e.scrollTo(0,n))},h=function(t,n,r,i){if(!(!n.emitEvents||typeof e.CustomEvent!=`function`)){var a=new CustomEvent(t,{bubbles:!0,detail:{anchor:r,toggle:i}});document.dispatchEvent(a)}};return function(a,g){var _={},v,y,b,x,S,C;_.cancelScroll=function(e){cancelAnimationFrame(C),C=null,!e&&h(`scrollCancel`,v)},_.animateScroll=function(n,i,a){var o=r(v||t,a||{}),s=Object.prototype.toString.call(n)===`[object Number]`,g=s||!n.tagName?null:n;if(!(!s&&!g)){var y=e.pageYOffset;o.header&&!b&&(b=document.querySelector(o.header)),x||=d(b);var S=s?n:u(g,x,parseInt(typeof o.offset==`function`?o.offset(n,i):o.offset,10),o.clip),w=S-y,T=l(),E=0,D=f(w,o),O,k,A,j=function(t,r){var a=e.pageYOffset;if(t==r||a==r||(y<r&&e.innerHeight+a)>=T)return _.cancelScroll(!0),m(n,r,s),h(`scrollStop`,o,n,i),O=null,C=null,!0}
1,M=function(t){O||=t,E+=t-O,k=E/parseInt(D,10),k=k>1?1:k,A=y+w*c(o,k),e.scrollTo(0,Math.floor(A)),j(A,S)||(C=e.requestAnimationFrame(M),O=t)};e.pageYOffset===0&&e.scrollTo(0,0),p(n,s,o),h(`scrollStart`,o,n,i),_.cancelScroll(!0),e.requestAnimationFrame(M)}};var w=function(t){if(!i(v)&&!(t.button!==0||t.metaKey||t.ctrlKey)&&`closest`in t.target&&(y=t.target.closest(a),!(!y||y.tagName.toLowerCase()!==`a`||t.target.closest(v.ignore))&&!(y.hostname!==e.location.hostname||y.pathname!==e.location.pathname||!/#/.test(y.href)))){var n=s(o(y.hash)),r=v.topOnEmptyHash&&n===`#`?document.documentElement:document.querySelector(n);r=!r&&n===`#top`?document.documentElement:r,r&&(t.preventDefault(),_.animateScroll(r,y))}},T=function(e){if(history.state!==null&&!(!history.state.smoothScroll||history.state.smoothScroll!==JSON.stringify(v))&&history.state.anchor){var t=document.querySelector(s(o(history.state.anchor)));t&&_.animateScroll(t,null,{updateURL:!1})}},E=function(e){S||=setTimeout((function(){S=null,x=d(b)}),66)};return _.destroy=function(){v&&(document.removeEventListener(`click`,w,!1),e.removeEventListener(`resize`,E,!1),e.removeEventListener(`popstate`,T,!1),_.cancelScroll(),v=null,y=null,b=null,x=null,S=null,C=null)},_.init=function(i){if(!n())throw`Smooth Scroll: This browser does not support the required JavaScript methods and browser APIs.`;_.destroy(),v=r(t,i||{}),b=v.header?document.querySelector(v.header):null,x=d(b),document.addEventListener(`click`,w,!1),b&&e.addEventListener(`resize`,E,!1),v.updateURL&&v.popstate&&e.addEventListener(`popstate`,T,!1)},_.init(g),_}}))})),r=new(e(n(),1)).default,i=e=>{let t=document.getElementById(e);t&&requestAnimationFrame(()=>{r.animateScroll(t,void 0,{speed:1e3,speedAsDuration:!0})})};export{n,i as t};

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.