"use strict";function gscounteranimate(obj,initVal,lastVal,duration,postfix){let startTime=null,currentTime=Date.now();const step=currentTime=>{startTime||(startTime=currentTime);const progress=Math.min((currentTime-startTime)/(1e3*duration),1);let postfixhtml=postfix||"";const formatter=new Intl.NumberFormat;obj.innerHTML=formatter.format(Math.floor(progress*(lastVal-initVal)+initVal))+postfixhtml,progress<1?window.requestAnimationFrame(step):(window.cancelAnimationFrame(window.requestAnimationFrame(step)),obj.classList.add("countfinished"))};window.requestAnimationFrame(step)}const gspbInviewCounters=document.getElementsByClassName("gs-counter");let gspbinviewcounterobserve=new IntersectionObserver(entries=>{entries.forEach(entry=>{if(entry.isIntersecting){let counterobj=entry.target;if(!counterobj.classList.contains("countfinished")){let start=parseInt(counterobj.dataset.start),end=parseInt(counterobj.dataset.end),postfix=counterobj.dataset.postfix,duration;gscounteranimate(counterobj,start,end,parseFloat(counterobj.dataset.duration),postfix)}}})},{threshold:.3});for(let itemobserve of gspbInviewCounters)gspbinviewcounterobserve.observe(itemobserve);