1try{let e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},t=(new e.Error).stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]="f947b42b-eded-45fa-b436-7dd5b6366ff5",e._sentryDebugIdIdentifier="sentry-dbid-f947b42b-eded-45fa-b436-7dd5b6366ff5")}catch(e){}"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[39231],{39231:(e,t,o)=>{o.d(t,{DemoLeadForm:()=>A});var l=o(95155),r=o(83801),s=o(50353),a=o(35515),n=o(54956),m=o(12895),i=o(22544),x=o(13611),d=o(35068),c=o(18900),u=o(12482),f=o(38008),p=o(51206),b=o(12115),h=o(20765),y=o(494),g=o(11529),k=o(95501),w=o(79691),C=o(12692),v=o(20063),j=o(95125),T=o(62220),E=o(10896),B=o(15373),N=o(47131);let I={v1:{formInputWrapper:"w-[310px] max-w-full max-sm:mb-2 max-sm:w-full",formInput:"h-14 w-full rounded-[5px] border border-solid border-[#BDBDBD] p-4 text-lg text-black focus-visible:outline-none max-sm:text-center sm:rounded-r-none sm:border-r-0",formBtn:"h-14 !min-w-[180px] rounded-[5px] px-[30px] text-sm leading-[1.2] text-white transition md:text-base max-sm:w-full sm:rounded-l-none !font-medium max-sm:mt-3",cookieErrorClassname:"absolute -bottom-3.5 left-0 text-xs font-normal leading-tight text-[#F75635]",euCookieCheckBoxLabelClassname:"text-sm font-normal text-neutral-500",bottomText:"mt-3 !mb-0 text-sm text-zinc-700",formError:"!text-xs !text-red-600 !mt-0.5 !mb-0"},v2:{formInputWrapper:"w-80 max-w-full max-sm:mb-2 max-sm:w-full",formInput:"h-14 border border-slate-500/25 size-full rounded-2xl text-base sm:text-lg font-normal px-4 outline-none",formBtn:"h-14 sm:ml-3 rounded-2xl bg-red-500 hover:bg-red-600 !font-bold !px-6 max-sm:w-full max-sm:mt-2.5 !min-w-40",cookieErrorClassname:"absolute -bottom-3.5 left-0 text-xs font-normal leading-tight text-[#F75635]",euCookieCheckBoxLabelClassname:"text-sm font-normal text-neutral-500",bottomText:"mt-3 text-sm text-zinc-700 max-md:text-center",formError:"absolute mt-px text-xs text-red-600 max-sm:left-1/2 max-sm:-translate-x-1/2 sm:mt-0.5"},v3:{formContainerWrapper:"flex-col",formInputWrapper:"mb-1.5 w-full",formInput:"w-full rounded px-4 py-2 text-center text-sm font-normal focus-visible:outline-none max-sm:text-center border border-slate-200 rounded-xl",formBtn:"w-full rounded-xl !bg-black !p-2 !text-base !font-bold leading-5 text-white transition-all duration-300 hover:!bg-gray-900 mt-2 min-h-8",bottomText:"mt-1.5 text-center text-xs font-normal leading-snug text-white",formError:"mt-0.5 text-xs text-white",cookieErrorClassname:"mt-0.5 text-xs font-normal leading-tight text-white",euCookieCheckBoxLabelClassname:"text-xs min-w-4 font-normal text-white"},v4:{formInputWrapper:"w-[310px] max-w-full max-sm:mb-2 max-sm:w-full",formInput:"h-14 w-full rounded-[5px] border border-solid border-[#BDBDBD] p-4 text-lg text-black focus-visible:outline-none max-sm:text-center sm:rounded-r-none sm:border-r-0",formBtn:"h-14 !min-w-[180px] rounded-[5px] px-[30px] text-sm leading-[1.2] text-white transition md:text-base max-sm:w-full sm:rounded-l-none !font-medium max-sm:mt-3",bottomText:"mt-3 text-sm text-white",formError:"absolute mt-px text-xs text-red-600 max-sm:left-1/2 max-sm:-translate-x-1/2 sm:mt-0.5",cookieErrorClassname:"mt-0.5 text-xs font-normal leading-tight text-white",euCookieCheckBoxLabelClassname:"text-xs font-normal text-white"},v5:{formContainerWrapper:"rounded-xl",formInputWrapper:"w-80 max-w-full max-sm:mb-2 max-sm:w-full ",formInput:"!min-h-10 size-full rounded-lg text-base sm:text-base font-normal px-4 outline-none",formBtn:"!min-h-10 sm:ml-3 !text-sm rounded-lg bg-slate-700 xl:hover:bg-black !font-bold !px-4 max-sm:w-full max-sm:mt-2.5 !min-w-36",bottomText:"!text-xs !font-normal !text-white !leading-4 mt-2 !text-center",formError:"mt-px !text-xs !text-red-600 sm:mt-0.5 !mb-0 absolute top-10",cookieErrorClassname:"mt-0.5 !text-xs !font-normal leading-tight !text-red-600 !mb-0",euCookieCheckBoxLabelClassname:"!text-xs font-normal !text-white"}};var D=o(73263),P=o(10770);function A(e){let t,{siteType:o=u.u.main,align:A="left",placeholder:L=N.P[o].emailPlaceholder,bottomText:W=N.P[o].bottomText,btnColor:S="primary",variant:_="v1",btnText:F="Book a call",ctaColor:R="",ctaHoverColor:O="",leadSource:z="SS Demo Form",formClassName:U="",hasEmailLabel:M=!1,customBottomTextClassName:Z=""}=e,[q,Q]=(0,b.useTransition)(),$=d.Ik().shape({email:d.Yj().email(N.P[o].emailValidText).required(N.P[o].emailRequiredText),isCookieyesAccepted:d.zM().oneOf([!0],N.P[o].emailCookiePolicyText).required(N.P[o].emailCookiePolicyText)}),V=(0,b.useRef)(null);(0,b.useEffect)(()=>{V.current.style.minWidth="".concat(V.current.offsetWidth,"px")}
1,[]);let[G,H]=(0,b.useState)(!1),[J,K]=(0,b.useState)(!1),[Y,X]=(0,b.useState)({}),[ee,et]=(0,b.useState)(!1),[eo,el]=(0,b.useState)({employeeNumber:null,countryList:null}),er=(0,v.usePathname)(),es=()=>{H(!1)},{register:ea,handleSubmit:en,setError:em,setValue:ei,control:ex,formState:{errors:ed}}=(0,i.mN)({resolver:(0,x.t)($)});(0,h.R)("ipapi_data").length>1&&(t=(0,k.E)((0,h.R)("ipapi_data"),[]));let ec=(0,C.k)();(0,b.useEffect)(()=>{(0,g.g$)("preDemoUrl",er),(0,h.T)("preDemoUrl",er)},[er]);let eu=async e=>{let{email:l,isCookieyesAccepted:r}=e;if(ee&&r){var s;if("function"==typeof(null==(s=window)?void 0:s.performBannerAction))try{window.performBannerAction("accept_all")}catch(e){em("isCookieyesAccepted",{type:"custom",message:N.P[o].somethingWentWrongText})}}let a=(0,h.R)("hubspotutk"),n=l.split("@").pop(),{isPersonal:m,isDisposable:i,isRestricted:x}=await (0,w.$)(n),d=c.yv.includes(n);(0,g.Tp)("personal_id",m),(0,g.Tp)("email_id",l);let u=(0,P.n9)(n),b=Array.isArray(t)&&t.length>0?t[0]:"";if(m||i||x||d){Q(()=>{H(!1)}),em("email",{type:"custom",message:N.P[o].businessEmailErrorText});return}Q(()=>{H(!0)});let y=(0,g.kl)(f.by)||(0,h.R)(f.by),k=(0,g.kl)(f.WZ),C=(0,g.kl)(f.si),v={email:l,timeZone:Intl.DateTimeFormat().resolvedOptions().timeZone,isBusinessEmail:!m,ssUserId:(0,h.R)(f.JU)||null,device:ec};k&&(v.ssTrackerLocation=k),C&&(v.ssTrackerReferrer=C);let T=(0,g.kl)("preDemoUrl")||(0,h.R)("preDemoUrl");T&&(v.preDemoUrl=T),y&&(v.ssFirstPageSeen=y),a&&(v.hubspotUtk=a),z&&(v.leadSource=z),p.F.forEach(e=>{let t=Object.keys(e),o=(0,g.kl)(t)||(0,h.R)(t);o&&(v[t]=o)});let E=(0,P.cO)(o);E&&(v.websiteLanguage=E),j.A.post("".concat("https://app.surveysparrow.com","/api/internal/add-lead"),v).catch(()=>{em("email",{type:"custom",message:N.P[o].somethingWentWrongText})}),window.dataLayer=window.dataLayer||[],window.dataLayer.push({event:"Email-field"}),window.dataLayer.push({event:"demo form",eventModel:{email:l}}),X({email:l,companyName:u}),(0,P.Fi)(n,el,b)},ef=(0,b.useCallback)(function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:t;(null==e?void 0:e[1])===!0||(null==e?void 0:e[2])==="GB"||(null==e?void 0:e[2])==="CH"?et(!0):"string"==typeof(null==e?void 0:e[2])?(et(!1),ei("isCookieyesAccepted",!0)):et(!0)},[t,ei]),ep=(0,b.useCallback)(()=>{ef()},[ef]),eb=(0,b.useCallback)(async()=>{ef((0,k.E)(await (0,y.K)(),[]))},[ef]);(0,b.useEffect)(()=>{t?ep():eb()},[t,ep,eb]);let eh=(0,b.useCallback)(e=>{Q(()=>{H(e)})},[]);return(0,l.jsxs)("div",{children:[(0,l.jsxs)("form",{className:"relative flex flex-col",onSubmit:en(eu),method:"post",children:[M&&(0,l.jsx)(a.lR,{htmlFor:"email",label:"Work Email*",className:"mb-1 ml-2 text-sm font-normal leading-normal text-slate-400"}),(0,l.jsxs)("div",{className:"relative flex ".concat(A?({left:["justify-left","text-left"],center:["justify-center","text-center"],right:["justify-end","text-right"]})[A][0]:"justify-left"," ").concat(I[_].formContainerWrapper," max-sm:flex-wrap ").concat(U),children:[(0,l.jsxs)("div",{className:I[_].formInputWrapper,children:[(0,l.jsx)(a.ZQ,{type:"email",placeholder:L||"[email protected]",className:I[_].formInput,...ea("email")}),ed.email&&(0,l.jsx)(a.jQ,{className:I[_].formError,error:ed.email.message})]}),(0,l.jsx)(r.$,{type:"submit",color:S,className:I[_].formBtn,ref:V,handleMouseEnter:()=>{K(!0)},handleMouseOut:()=>{K(!1)},background:J?O:R,onTouchStart:e=>{e.currentTarget.style.touchAction="none"},children:q?"Loading...":F})]})]}),ee&&(0,l.jsxs)("div",{className:"relative",children:[(0,l.jsx)("div",{className:"mt-2 flex items-center gap-x-[9px] max-md:justify-center sm:mt-5",children:(0,l.jsx)(i.xI,{name:"isCookieyesAccepted",control:ex,defaultValue:!1,render:e=>{let{field:{onChange:t,value:r}}=e;return(0,l.jsxs)(l.Fragment,{children:[(0,l.jsx)(s.y,{id:"isCookieyesAccepted",checked:r,onCheckedChange:t,name:"isCookieyesAccepted",className:"data-[state=checked]:border-primary data-[state=checked]:bg-primary -mt-px flex size-4 min-w-4 cursor-pointer items-center justify-center rounded-sm border border-slate-500/25 outline-none ".concat(I[_].cookieyesCheckBoxClassName),children:(0,l.jsx)(s.P,{className:"size-full scale-75",children:(0,l.jsx)(T.N,{})})}),(0,l.jsx)(a.lR,{label:"".concat(N.P[o].agreeToCookiePolicyText," ").concat(N.P[o].agreeToCookiePolicyTextToScheduleDemo),htmlFor:"isCookieyesAccepted",className:I[_].euCookieCheckBoxLabelClassname})]})}})}),ed.isCookieyesAccepted&&(0,l.jsx)(a.jQ,{className:I[_].cookieErrorClassname,error:ed.isCookieyesAccepted.message})]}),W?(0,l.jsx)(m.E,{className:"".concat(I[_].bottomText," ").concat(Z),children:W}):null,(0,l.jsx)(n.aF,{open:G,onOpenChange:eh,onDismiss:es,children:(0,l.jsxs)(n.t9,{isOpen:G,className:"max-xs:fixed max-xs:h-full max-xs:max-h-full max-xs:w-full max-xs:rounded-none xs:!rounded-3xl overflow-y-auto pb-10 pt-12",disableOutsideClickClose:!0,children:[(0,l.jsx)("div",{className:"flex justify-between",children:(0,l.jsx)(n.Oj,{onClick:es,className:"absolute right-3.5 top-4 z-50",children:(0,l.jsx)(B.I,{onClick:es,iconComponent:E.O,color:"#6A6A6A",width:"30",height:"30"})})}),(0,l.jsx)(b.Suspense,{children:(0,l.jsx)(D.M9,{data:Y,numberOfEmployees:eo.employeeNumber,countryList:eo.countryList})})]})})]})}}}]);
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.