"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[5024],{23767:function(e,t,s){s.d(t,{S:function(){return r}});var n=s(7297),a=s(31157);function i(){var e=(0,n.Z)(["\n  padding: 0;\n\n  "," {\n    padding: 2rem 0;\n  }\n\n  .sub-message {\n    text-align: center;\n  }\n"]);return i=function(){return e},e}var r=a.ZP.div.withConfig({componentId:"sc-6bc2f3d6-0"})(i(),function(e){return e.theme.media.md})},5024:function(e,t,s){s.d(t,{Z:function(){return et}});var n=s(47568),a=s(26042),i=s(69396),r=s(97582),l=s(85893),o=s(67294),c=s(27484),u=s.n(c),d=s(36808),m=s.n(d),h=s(70178),v=s.n(h),f=s(29387),g=s.n(f),p=s(28734),x=s.n(p),b=s(78862),j=s(51394),_=s(44195),y=s(11163),S=s(9669),N=s.n(S),C=s(82580),Z=s(41609),E=s.n(Z),w=s(53209),T=s(11269),D=s(90223),I=s(31838),k=s(54352),B=s(5012),P=s(94155),F=s(4488),M=s(38785),O=s(61783),q=s(70321),A={first_name:w.Z_().min(1,"Must have at least one character").required("Please enter your first name"),last_name:w.Z_().min(1,"Must have at least one character").max(255,"Must be shorter than 255 characters").required("Please enter your last name"),email:w.Z_().email("Please enter a valid email address").required("Please enter your email address"),phone:w.Z_().matches(/^(\([0-9]{3}\) |[0-9]{3}-)[0-9]{3}-[0-9]{4}$/,"Please enter a valid phone number").required("Please enter your phone number"),business_name:w.Z_().min(1,"Must have at least one character").matches(/^(?!\s*$|\s).*$/,"Cannot be blank or begin with a space").required("Please enter your business name"),industry:w.Z_().required("Please select your industry")},L=function(e){var t=e.appointment,s=e.account,i=void 0===s?null:s,c=e.buttonText,d=void 0===c?"Confirm My Appointment":c,m=e.close,h=e.reset,v=e.stage,f=e.submit,g=e.title,p=e.submitError,x=(e.tosText,e.onBack),b=e.localizationFields,j=void 0===b?k.Z.en:b,_=e.AdditionalQuestions,y=void 0!==_&&_,S=e.hideCloseButton,Z=(0,o.useState)({}),L=Z[0],z=Z[1],Y=(0,o.useState)(!1),R=Y[0],J=Y[1],Q=(0,o.useState)(null),U=Q[0],H=Q[1],$=(0,o.useState)(null),V=$[0],W=$[1],G=(0,o.useState)(null),K=G[0],X=G[1],ee=(0,o.useState)(null),et=ee[0],es=ee[1],en={},ea={first_name:i?null==i?void 0:i.first_name:"",last_name:i?null==i?void 0:i.last_name:"",email:i?null==i?void 0:i.email:"",phone:i?null==i?void 0:i.phone:"",business_name:i?null==i?void 0:i.business_name:"",industry:i?null==i?void 0:i.industry:"",sms_opt_in:!i||(null==i?void 0:i.sms_opt_in)};if(y&&void 0!==y||((y={}).expected_annual_revenue=!1),y.expected_annual_revenue&&(ea.expected1stYearRevenue="",en.expected1stYearRevenue=w.Z_().required("Please select an option")),"undefined"!=typeof sessionStorage&&sessionStorage.getItem("VWO_variation")){var ei=JSON.parse(localStorage.getItem("query"))||{};ei.utm_content="vwo_v1",localStorage.setItem("query",JSON.stringify(ei))}var er,el,eo=w.Ry().shape((0,a.Z)({},A,en)),ec=(er=(0,n.Z)(function(){var e;return(0,r.__generator)(this,function(e){switch(e.label){case 0:return[4,N().get(I.uK.websiteConfig)];case 1:return z(e.sent().data.picklist_options),[2]}})}),function(){return er.apply(this,arguments)}),eu=(0,o.useRef)(!1);(0,o.useEffect)(function(){return eu.current=!0,function(){eu.current=!1}},[]),(0,o.useEffect)(function(){ec()},[]),(0,o.useEffect)(function(){var e=JSON.parse(sessionStorage.getItem("scheduleFormData")),t=JSON.parse(sessionStorage.getItem("scheduleFormContext"));e&&t&&ed(e,t)},[]),(0,o.useEffect)(function(){h&&J(!1)},[h]);var ed=(el=(0,n.Z)(function(e,t){return(0,r.__generator)(this,function(s){switch(s.label){case 0:return J(!0),sessionStorage.setItem("scheduleFormData",JSON.stringify(e)),sessionStorage.setItem("scheduleFormContext",JSON.stringify(t)),[4,f(e,t,!0)];case 1:return s.sent(),eu.current&&J(!1),[2]}})}),function(e,t){return el.apply(this,arguments)});return(0,o.useEffect)(function(){ec()},[]),(0,o.useEffect)(function(){es(u()(new Date).format("z"));var e,s=new Date(0);s.setUTCMilliseconds(t.selectedTime);var n=s.getHours(),a=s.getMinutes();X(30===a?String(T.Z[String(n)+String(a)]):String(T.Z[String(n)])),H(s.getMonth()+1),W(s.getDate())},[]),(0,l.jsx)(M.Z,{hideCloseButton:void 0!==S&&S,active:"form"===v,close:m,onBack:x,children:(0,l.jsx)(q.U,{"data-cy":"scheduler-additional-fields",children:(0,l.jsx)("div",{className:"container",children:(0,l.jsx)("div",{className:"row",children:(0,l.jsx)("div",{className:"col-12 col-md-12",children:(0,l.jsxs)("section",{className:"questions",children:[(0,l.jsx)("h3",{className:R?"title hidden":"title",children:g}),(0,l.jsx)("div",{className:"form-wrap",children:(0,l.jsx)(O.cc,{children:function(e){var s;return(0,l.jsx)(C.J9,{enableReinitialize:!0,initialValues:ea,validationSchema:eo,onSubmit:(s=(0,n.Z)(function(t,s){var n;return(0,r.__generator)(this,function(a){return n=s.setSubmitting,ed(t,e),n(!0),[2]})}),function(e,t){return s.apply(this,arguments)}),children:function(e){var s=e.values,n=e.errors,a=e.touched,i=e.handleChange,r=e.handleBlur,o=e.handleSubmit,c=e.isSubmitting;return(0,l.jsxs)(l.Fragment,{children:[(0,l.jsxs)(C.l0,{onSubmit:o,className:R?"is-loading":"",children:[(0,l.jsxs)("div",{className:"form-background",children:[t&&(0,l.jsx)("div",{className:"schedule-time",children:"Scheduled for ".concat(U,"/").concat(V," at ").concat(K," ").concat(et)}),(0,l.jsx)(B.Z,{id:"first_name",label:j.nameField,values:s,touched:a,errors:n,handleChange:i,handleBlur:r,tests:eo.fields.first_name.tests}),(0,l.jsx)(B.Z,{id:"last_name",label:j.lastnameField,values:s,touched:a,errors:n,handleChange:i,handleBlur:r,tests:eo.fields.last_name.tests}),(0,l.jsx)(B.Z,{id:"email",label:j.emailField,type:"email",values:s,touched:a,errors:n,handleChange:i,handleBlur:r,tests:eo.fields.email.tests,info:"We’ll send the appointment confirmation to your inbox."}),(0,l.jsx)(B.Z,{id:"phone",label:j.phoneField,values:s,touched:a,errors:n,handleChange:i,handleBlur:r,type:"tel",tests:eo.fields.phone.tests,info:"A small business specialist will call you at the date and time you selected."}),(0,l.jsx)(B.Z,{id:"business_name",label:j.businessNameField,values:s,touched:a,errors:n,handleChange:i,handleBlur:r,tests:eo.fields.business_name.tests,info:"Input the name of your business. If you don’t have a business, please put ‘none’."}),(0,l.jsx)(P.Z,{id:"industry",label:j.industry,touched:a,errors:n,handleChange:i,handleBlur:r,values:s,options:L.industry,addNoneOption:!0,tests:eo.fields.industry.tests,info:"Select the industry that best describes your business. If you don't see an industry that matches your business, select 'other'."}),y.expected_annual_revenue&&(0,l.jsx)(P.Z,{id:"expected1stYearRevenue",label:j.expected1stYearRevenue,touched:a,errors:n,handleChange:i,handleBlur:r,tests:eo.fields.expected1stYearRevenue.tests,values:s,options:L.expected_1st_year_revenue,info:"This information helps us match you with the best accountant for your situation. If you’re not in business yet, please select $0. "}),p?(0,l.jsx)(F.Z,{type:"error",message:p}):null]}),(0,l.jsx)("div",{children:(0,l.jsx)("button",{type:"submit",label:"",className:"btn btn-submit btn-secondary btn-block",disabled:c||!E()(n),children:d})}),(0,l.jsx)("div",{className:"terms-text",children:(0,l.jsx)(D.Z,{id:"sms_opt_in",buttonText:d})})]}),R&&(0,l.jsxs)("div",{className:"loading-message",children:[(0,l.jsx)("h4",{children:"Just a moment…"}),(0,l.jsxs)("p",{children:["We're scheduling your appointment...",(0,l.jsx)("br",{}),(0,l.jsx)("strong",{children:"Please keep this window open."})]})]})]})}})}})})]})})})})})})},z=s(10229),Y=s(51436),R=s(92814),J=s(70472),Q=s(16228),U=s(62501),H=s(43315),$=s(25940);u().extend(v()),u().extend(g()),u().extend(x());var V=function(e){var t=e.appointment,s=(e.calendarEventTitle,e.calendarEventDetails,e.close),a=e.title,i=e.subTitle,c=(e.accountant,e.realAccountantDetails),d=void 0===c?null:c,m=e.customClass,h=(0,o.useState)(!1),v=h[0],f=h[1],g=u().tz.guess();return"accounting-services-v2-business"===(void 0!==m&&m)&&(d.UserPhoto,d.UserName),t.selectedTime,u()(t.selectedTime).add(30,"m").toDate(),(0,o.useEffect)(function(){(null==window?void 0:window.fbq)&&window.fbq("track","Lightbox Appointment Scheduled")},[]),(0,o.useEffect)(function(){var e;(e=(0,n.Z)(function(){var e;return(0,r.__generator)(this,function(e){switch(e.label){case 0:return[4,(0,Q.Z)()];case 1:return f(e.sent()),[2]}})}),function(){return e.apply(this,arguments)})(),setTimeout((0,n.Z)(function(){return(0,r.__generator)(this,function(e){return(0,H.Z)(),[2]})}),4e3)},[]),(0,l.jsxs)($.U,{className:"scheduler-thank-you",children:[s&&(0,l.jsx)("button",{type:"button",className:"close-btn",onClick:s,children:(0,l.jsx)(R.G,{icon:Y.NBC,color:"#333"})}),v?(0,l.jsx)(U.default,{shareASaleHash:v,transType:"lead"}):"",(0,l.jsx)("div",{className:"container text-center",children:(0,l.jsxs)("div",{className:"col-md-6 col-12 pt-4",children:[(0,l.jsx)("h1",{className:"title",children:a||"Talk To You Soon!"}),(0,l.jsx)("p",{className:"subtitle",children:i}),(0,l.jsx)("div",{className:"row appointment-details mt-4",children:(0,l.jsxs)("div",{className:"col-md-8 offset-md-2 n",children:[(0,l.jsxs)("div",{className:"date",children:[(0,l.jsx)(J.Q,{className:"svg-container",src:"/static/images/icons/scheduler/calendar-white-3.svg?type=svg"}),t&&(0,l.jsx)("h3",{children:u()(t.selectedDate).format("dddd, MMM DD, YYYY")})]}),(0,l.jsxs)("div",{className:"time",children:[(0,l.jsx)(J.Q,{className:"svg-container",src:"/static/images/icons/scheduler/clock-white-3.svg?type=svg"}),t&&(0,l.jsx)("h3",{children:u()(t.selectedTime).format("hh:mm A")})]}),(0,l.jsxs)("div",{className:"timezone",children:[(0,l.jsx)(J.Q,{className:"svg-container",src:"/static/images/icons/scheduler/globe-white-3.svg?type=svg"}),(0,l.jsx)("h3",{children:g})]})]})})]})})]})};s(61608);var W=s(86174),G=s(7454),K=function(e){var t,s=e.close,n=e.handleNextStep,a=e.stage,i=e.campaign,r=e.data,o=e.submitting,c=e.PaidCampaign,u=e.EntityCampaign,d=e.localizationStrings,m=void 0===d?k.Z.en:d,h=e.setCurrentStep,v=e.setIsLoading,f=e.customClass,g=e.NumDaysOverride,p=(e.isTaxServicesLLC,e.errorMessage),x=void 0===p?null:p,b=e.EForm,j=e.setSchedulerErrorMessage;c=(0,_.Z)(c);var y=!1;return r&&(r.accountant_details,r.paid_campaign,y=r.is_stimulus),(0,l.jsxs)(G.m,{className:void 0!==f&&f,children:[(0,l.jsx)("div",{className:"container",children:(0,l.jsx)("div",{className:"row justify-content-center",children:(0,l.jsx)("div",{className:"col-12 col-md-10",children:(0,l.jsx)("div",{className:"sub-message",children:"Select a time and we’ll give you a call"})})})}),x?(0,l.jsxs)("div",{className:"error-message",children:[(0,l.jsx)("img",{src:"/icons/danger.png",alt:"danger icon",width:"50px",height:"50px"})," ",x]}):"",(0,l.jsx)("div",{children:(0,l.jsx)(W.Z,{close:s,handleNextStep:n,mode:"slideup",PaidCampaign:c,EntityCampaign:void 0!==u&&u,isStimulus:y?"1":"0",stage:a,campaign:i,submitting:o,appointmentText:m.appointmentText,confirmText:m.confirmText,setCurrentStep:void 0!==h&&h,setIsLoading:void 0!==v&&v,NumDaysOverride:void 0===g?null:g,EForm:void 0!==b&&b,setSchedulerErrorMessage:void 0===j?null:j})}),(0,l.jsx)("div",{className:"container",children:(0,l.jsxs)("div",{className:"scheduler-testimonial col-12 col-md-10",children:[(0,l.jsx)("img",{src:"".concat(I.qt.media,"/2022/07/huong-t.png"),alt:"Huong T - Testimonial image"}),(0,l.jsxs)("div",{children:[(0,l.jsx)("div",{className:"text",children:'"Excellent first call, very informative. This is my third business... this time I will ease the burden and use 1-800Accountant [for accounting]"'}),(0,l.jsx)("div",{className:"author",children:"Huong T."})]})]})})]})},X=s(23767),ee=s(19293);u().extend(v()),u().extend(g()),u().extend(x());var et=function(e){var t=e.account,s=e.data,c=e.callBack,d=e.onSuccess,h=e.update,v=void 0!==h&&h,f=e.onClose,g=e.restartOnClose,p=void 0!==g&&g,x=e.PaidCampaign,S=e.phoneNumber,N=void 0===S?"18002226868":S,C=e.AdditionalQuestions,Z=e.onDateSelect,E=e.customSubmitting,w=e.EntityCampaign,T=void 0!==w&&w,D=e.language,I=void 0===D?"en":D,B=e.setCurrentStep,P=void 0!==B&&B,F=e.setIsLoading,M=e.customClass,O=void 0!==M&&M,q=e.NumDaysOverride,A=e.AssignOwner,Y=void 0!==A&&A,R=e.doElite,J=void 0!==R&&R,Q=e.isTaxServicesLLC,U=e.EForm,H=void 0!==U&&U,$=e.hideCloseButton,W=void 0!==$&&$,G=s.scheduler,et=s.form,es=s.thank_you,en=(0,_.Z)(x),ea=(0,o.useState)(null),ei=ea[0],er=ea[1],el=(0,o.useState)(null),eo=el[0],ec=el[1],eu=(0,o.useState)(ee.f),ed=eu[0],em=eu[1],eh=(0,o.useState)(null),ev=eh[0],ef=eh[1],eg=(0,o.useState)("scheduler"),ep=eg[0],ex=eg[1],eb=(0,o.useState)(!1),ej=eb[0],e_=eb[1],ey=(0,o.useState)(),eS=ey[0],eN=ey[1],eC=(0,o.useState)(k.Z.en),eZ=eC[0],eE=eC[1],ew=(0,o.useState)(null),eT=ew[0];ew[1];var eD=(0,y.useRouter)(),eI=null==eD?void 0:eD.asPath;(0,o.useEffect)(function(){var e=u().tz.guess();eN(e)},[]),(0,o.useEffect)(function(){"es"===I&&eE(k.Z.es)},[I]),(0,o.useEffect)(function(){P&&ev&&eP()},[ev]),(0,o.useEffect)(function(){P&&(0,n.Z)(function(){var e;return(0,r.__generator)(this,function(t){return e=m().get("ContactID"),em({leadID:e}),[2]})})()},[]),(0,o.useEffect)(function(){if(v){var e=m().get("ContactID"),t=m().get("LeadID");em({leadID:t,contactID:e})}},[]);var ek,eB=function(){if(ef(null),f&&f(),p){ex("scheduler");return}ex(null)},eP=(ek=(0,n.Z)(function(e,t){var s,n,a,i,l=arguments;return(0,r.__generator)(this,function(t){switch(t.label){case 0:return s=!(l.length>2)||void 0===l[2]||l[2],e_(!0),er(null),ec(""),n=!!P,a=(0,j.default)(),[4,(0,b.CX)(ev,en,e,N,eS,ed,em,er,v,T,I,Y,n,J,H,s,eI)];case 1:return i=t.sent(),d?d():(c&&c({response:i,formData:e,leadValues:a,selectedAppointment:ev}),e_(!1),ex("thanks")),[2]}})}),function(e,t){return ek.apply(this,arguments)});(0,o.useEffect)(function(){ev&&!P&&ex("form")},[ev]);var eF=function(e){P?(0,n.Z)(function(){return(0,r.__generator)(this,function(t){return ef(e),[2]})})():ef(e)};return(0,l.jsx)(ee.z.Provider,{value:(0,i.Z)((0,a.Z)({},ed),{set:em}),children:(0,l.jsxs)(X.S,{"data-cy":"universal-scheduler",children:["scheduler"===ep&&(0,l.jsx)(K,{handleNextStep:Z||eF,stage:ep,data:G,formData:et,close:eB,submitting:ej||E,PaidCampaign:en,EntityCampaign:T,localizationStrings:eZ,setCurrentStep:P,setIsLoading:void 0!==F&&F,customClass:O,NumDaysOverride:void 0===q?null:q,isTaxServicesLLC:Q,EForm:H,errorMessage:eo,setSchedulerErrorMessage:ec}),"form"===ep&&(0,l.jsx)(L,{appointment:ev,onBack:function(){return ex("scheduler")},account:void 0===t?null:t,campaign:et.service_type,close:eB,stage:ep,submit:eP,submitError:ei,data:G,AdditionalQuestions:C,localizationFields:eZ,title:eZ.schedulerTitle,tosText:eZ.tosText,buttonText:eZ.schedulerButtonText,hideCloseButton:W}),"existing-customer"===ep&&(0,l.jsx)(z.Z,{onBack:function(){return ex("scheduler")},close:eB,hideCloseButton:W,submit:eP,stage:ep}),"thanks"===ep&&(0,l.jsx)(V,{appointment:ev,title:es.title,subTitle:es.sub_title,accountant:G.accountant_details,calendarEventTitle:es.calendar_event_title,calendarEventDetails:es.calendar_event_description,close:p?eB:null,localizationStrings:eZ,realAccountantDetails:eT,customClass:O})]})})}}}]);