PageSourceSearch

https://digst.dk/dist/assets/numbers-Cyr_obpB.js

js digst.dk collected 2026-09-24 08:31:51 UTC 6,586 bytes, 1 lines download raw bytes

vendor: 5,256 bytes, line 1
1var b=function(){return b=Object.assign||function(s){for(var n,i=1,e=arguments.length;i<e;i++)for(var t in n=arguments[i])Object.prototype.hasOwnProperty.call(n,t)&&(s[t]=n[t]);return s},b.apply(this,arguments)},v=function(){function s(n,i,e){var t=this;this.endVal=i,this.options=e,this.version="2.8.0",this.defaults={startVal:0,decimalPlaces:0,duration:2,useEasing:!0,useGrouping:!0,useIndianSeparators:!1,smartEasingThreshold:999,smartEasingAmount:333,separator:",",decimal:".",prefix:"",suffix:"",enableScrollSpy:!1,scrollSpyDelay:200,scrollSpyOnce:!1},this.finalEndVal=null,this.useEasing=!0,this.countDown=!1,this.error="",this.startVal=0,this.paused=!0,this.once=!1,this.count=function(a){t.startTime||(t.startTime=a);var r=a-t.startTime;t.remaining=t.duration-r,t.useEasing?t.countDown?t.frameVal=t.startVal-t.easingFn(r,0,t.startVal-t.endVal,t.duration):t.frameVal=t.easingFn(r,t.startVal,t.endVal-t.startVal,t.duration):t.frameVal=t.startVal+(t.endVal-t.startVal)*(r/t.duration);var o=t.countDown?t.frameVal<t.endVal:t.frameVal>t.endVal;t.frameVal=o?t.endVal:t.frameVal,t.frameVal=Number(t.frameVal.toFixed(t.options.decimalPlaces)),t.printValue(t.frameVal),r<t.duration?t.rAF=requestAnimationFrame(t.count):t.finalEndVal!==null?t.update(t.finalEndVal):t.options.onCompleteCallback&&t.options.onCompleteCallback()},this.formatNumber=function(a){var r,o,l,u,f=a<0?"-":"";r=Math.abs(a).toFixed(t.options.decimalPlaces);var p=(r+="").split(".");if(o=p[0],l=p.length>1?t.options.decimal+p[1]:"",t.options.useGrouping){u="";for(var h=3,d=0,c=0,V=o.length;c<V;++c)t.options.useIndianSeparators&&c===4&&(h=2,d=1),c!==0&&d%h==0&&(u=t.options.separator+u),d++,u=o[V-c-1]+u;o=u}return t.options.numerals&&t.options.numerals.length&&(o=o.replace(/[0-9]/g,function(m){return t.options.numerals[+m]}),l=l.replace(/[0-9]/g,function(m){return t.options.numerals[+m]})),f+t.options.prefix+o+l+t.options.suffix},this.easeOutExpo=function(a,r,o,l){return o*(1-Math.pow(2,-10*a/l))*1024/1023+r},this.options=b(b({},this.defaults),e),this.formattingFn=this.options.formattingFn?this.options.formattingFn:this.formatNumber,this.easingFn=this.options.easingFn?this.options.easingFn:this.easeOutExpo,this.startVal=this.validateValue(this.options.startVal),this.frameVal=this.startVal,this.endVal=this.validateValue(i),this.options.decimalPlaces=Math.max(this.options.decimalPlaces),this.resetDuration(),this.options.separator=String(this.options.separator),this.useEasing=this.options.useEasing,this.options.separator===""&&(this.options.useGrouping=!1),this.el=typeof n=="string"?document.getElementById(n):n,this.el?this.printValue(this.startVal):this.error="[CountUp] target is null or undefined",typeof window<"u"&&this.options.enableScrollSpy&&(this.error?console.error(this.error,n):(window.onScrollFns=window.onScrollFns||[],window.onScrollFns.push(function(){return t.handleScroll(t)}),window.onscroll=function(){window.onScrollFns.forEach(function(a){return a()})},this.handleScroll(this)))}return s.prototype.handleScroll=function(n){if(n&&window&&!n.once){var i=window.innerHeight+window.scrollY,e=n.el.getBoundingClientRect(),t=e.top+window.pageYOffset,a=e.top+e.height+window.pageYOffset;a<i&&a>window.scrollY&&n.paused?(n.paused=!1,setTimeout(function(){return n.start()},n.options.scrollSpyDelay),n.options.scrollSpyOnce&&(n.once=!0)):(window.scrollY>a||t>i)&&!n.paused&&n.reset()}},s.prototype.determineDirectionAndSmartEasing=function(){var n=this.finalEndVal?this.finalEndVal:this.endVal;this.countDown=this.startVal>n;var i=n-this.startVal;if(Math.abs(i)>this.options.smartEasingThreshold&&this.options.useEasing){this.finalEndVal=n;var e=this.countDown?1:-1;this.endVal=n+e*this.options.smartEasingAmount,this.duration=this.duration/2}else this.endVal=n,this.finalEndVal=null;this.finalEndVal!==null?this.useEasing=!1:this.useEasing=this.options.useEasing},s.prototype.start=function(n){this.error||(this.options.onStartCallback&&this.options.onStartCallback(),n&&(this.options.onCompleteCallback=n),this.duration>0?(this.determineDirectionAndSmartEasing(),this.paused=!1,this.rAF=requestAnimationFrame(this.count)):this.printValue(this.endVal))},s.prototype.pauseResume=function(){this.paused?(this.startTime=null,this.duration=this.remaining,this.startVal=this.frameVal,this.determineDirectionAndSmartEasing(),this.rAF=requestAnimationFrame(this.count)):cancelAnimationFrame(this.rAF),this.paused=!this.paused},s.prototype.reset=function(){cancelAnimationFrame(this.rAF),this.paused=!0,this.resetDuration(),this.startVal=this.validateValue(this.options.startVal),this.frameVal=this.startVal,this.printValue(this.startVal)},s.prototype.update=function(n){cancelAnimationFrame(this.rAF),this.startTime=null,this.endVal=this.validateValue(n),this.endVal!==this.frameVal&&(this.startVal=this.frameVal,this.finalEndVal==null&&this.resetDuration(),this.finalEndVal=null,this.determineDirectionAndSmartEasing(),this.rAF=requestAnimationFrame(this.count))},s.prototype.printValue=function(n){var i;if(this.el){var e=this.formattingFn(n);!((i=this.options.plugin)===null||i===void 0)&&i.render?this.options.plugin.render(this.el,e):this.el.tagName==="INPUT"?this.el.value=e:this.el.tagName==="text"||this.el.tagName==="tspan"?this.el.textContent=e:this.el.
1innerHTML=e}},s.prototype.ensureNumber=function(n){return typeof n=="number"&&!isNaN(n)},s.prototype.validateValue=function(n){var i=Number(n);return this.ensureNumber(i)?i:(this.error="[CountUp] invalid start or end value: ".concat(n),null)},s.prototype.resetDuration=function(){this.startTime=null,this.duration=1e3*Number(this.options.duration),this.remaining=this.duration},s}();const w=".",g=",",y=s=>{const n=s.querySelector(".js-number");if(!n||!n.textContent)return;const i=n.textContent,e=i.includes(w),t=i.includes(g),a=i.indexOf(w),r=i.indexOf(g),o=e&&a>r,l=t&&r>a,u=s.dataset.animateNumber==="true",f=s.dataset.animationDuration,p=o?i.replace(new RegExp("\\B(?<!\\.\\d*)(?=(\\d{3})+(?!\\d))","g"),",").replaceAll(g,""):i.replaceAll(w,"").replaceAll(g,"."),h=Number(p),d=f?Number(f)/1e3:1.5,c=e&&o?".":",",V=e&&o?",":".",m=l||e&&!o?n.textContent.substring(n.textContent.indexOf(",")).length-1:o||t&&!l?n.textContent.substring(n.textContent.indexOf(".")).length-1:0,N=Number.isNaN(n),F=Number.isNaN(h);if(N)return console.error("Number",n.textContent,"is not a number");if(F)return console.error("End value",h,"is not a number");const E=new v(n,h,{enableScrollSpy:!0,duration:d,useGrouping:!(a==-1&&r==-1),decimal:c,separator:V,decimalPlaces:m,scrollSpyOnce:!0,startVal:u?0:h});E.error||E.start()};export{y as Numbers};

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.