import{_ as R,o as d,c as f,D as n,E as a,W as b,K as o,U as p,p as C,M as I,a as m,S as Q,q as T,z as k,A as U,O as h,T as z,a5 as D,J as F,G as X,V as M,a6 as N,aN as Z,aP as E,i as $,aQ as g,aR as S,aS as L,C as H,aT as j,aO as B,r as y,I as u,ak as G,aU as q,al as i,aq as P,a1 as c,af as K,a7 as J,a8 as W}from"./app-BFnHyeHm.js";import{T as Y}from"./index.esm-BIsv_TWP.js";import{A as x}from"./AuthFormHeader-DRNvTOqm.js";import{G as ee}from"./GuestLayout-FkLRvvEz.js";const le={props:{errors:{type:Object,required:!0}},emits:["ok","hide"],computed:{formattedErrors(){let e=[];for(const[s,_]of Object.entries(this.errors))s==="username"||s==="email"||s==="password"?e=[...e,..._]:e.push(`${s} is required`);return e}},methods:{show(){this.$refs.dialog.show()},hide(){this.$refs.dialog.hide()},onDialogHide(){this.$emit("hide")},onOKClick(){this.$emit("ok"),this.hide()},onCancelClick(){this.hide()}}};function se(e,s,_,t,v,r){return d(),f(N,{ref:"dialog",peristent:""},{default:n(()=>[a(M,{style:{width:"45vw"}},{default:n(()=>[a(b,{class:"bg-secondary text-white"},{default:n(()=>[o("h5",null,p(e.$t("registration_errors_dialog_title")),1)]),_:1}),a(b,null,{default:n(()=>[o("b",null,p(e.$t("registration_errors_dialog_line")),1),a(C),a(I,{class:"text-center q-py-lg",dense:""},{default:n(()=>[(d(!0),m(z,null,Q(r.formattedErrors,(V,w)=>(d(),f(T,{key:w,class:"text-start",dense:""},{default:n(()=>[a(k,{avatar:""},{default:n(()=>[a(U,{name:"warning"})]),_:1}),a(k,null,{default:n(()=>[h(p(V),1)]),_:2},1024)]),_:2},1024))),128))]),_:1})]),_:1}),a(C),a(D,null,{default:n(()=>[a(F),a(X,{color:"secondary",dense:"",onClick:r.onOKClick},{default:n(()=>[h(p(e.$t("continue")),1)]),_:1},8,["onClick"])]),_:1})]),_:1})]),_:1},512)}const oe=R(le,[["render",se]]),ae={name:"SignUp",components:{GuestLayout:ee,AuthFormHeader:x,PwdValidationTooltip:Z,TelephoneInput:E},setup(){return{isPwd:$(!0),isConfirmPwd:$(!0),pwdCriteriaVisible:$(!1)}},data:()=>({form:Y({company_name:null,company_address_1:null,company_address_2:null,company_address_3:null,company_address_4:null,company_address_5:null,company_city:null,company_state:null,company_zip:null,company_country:"US",company_first_name:null,company_last_name:null,company_phone:null,company_email:null,billing_address_1:null,billing_address_2:null,billing_address_3:null,billing_address_4:null,billing_address_5:null,billing_city:null,billing_state:null,billing_zip:null,billing_country:"US",billing_first_name:null,billing_last_name:null,billing_phone:null,billing_email:null,account_id:null,password:"",password_confirmation:"",first_name:null,last_name:null,username:null,email:null,same_as_primary:!1}),disableCompany:!1,emailAsId:!1,companyStateOptions:g,billingStateOptions:g,validationRule:{upper:!1,special:!1,num:!1,validation:!1},loading:!1,tenantData:{}}),computed:{address1Label(){return this.country==="MX"?this.$t("address_street1_mx")+" *":this.$t("address_street1")+" *"},address2Label(){return this.country==="MX"?this.$t("address_street2_mx"):this.$t("address_street2")},address3Label(){return this.country==="MX"?this.$t("address_street3_mx")+" *":this.$t("address_street3")},address4Label(){return this.country==="MX"?this.$t("address_street4_mx")+" *":this.$t("address_street4")},address5Label(){return this.$t("address_street5")},stateLabel(){return this.country==="CA"?this.$t("address_province")+" *":this.$t("address_state")+" *"},zipLabel(){return this.country==="US"?this.$t("address_zipcode")+" *":this.$t("address_postal_code")+" *"},address2Rules(){return[]},address3Rules(){return this.country==="MX"?[e=>!!e||this.$t("required_field")]:[]},address4Rules(){return this.country==="MX"?[e=>!!e||this.$t("required_field")]:[]},billingAddress1Label(){return this.billingCountry==="MX"?this.$t("address_street2_mx")+" *":this.$t("address_street2")+" *"},billingAddress2Label(){return this.billingCountry==="MX"?this.$t("address_street2_mx"):this.$t("address_street2")},billingAddress3Label(){return this.billingCountry==="MX"?this.$t("address_street3_mx")+" *":this.$t("address_street3")},billingAddress4Label(){return this.billingCountry==="MX"?this.$t("address_street4_mx")+" *":this.$t("address_street4")},billingAddress5Label(){return this.$t("address_street5")},billingStateLabel(){return this.billingCountry==="CA"?this.$t("address_province")+" *":this.$t("address_state")+" *"},billingZipLabel(){return this.billingCountry==="US"?this.$t("address_zipcode")+" *":this.$t("address_postal_code")+" *"},billingAddress2Rules(){return[]},billingAddress3Rules(){return this.billingCountry==="MX"?[e=>!!e||this.$t("required_field")]:[]},billingAddress4Rules(){return this.billingCountry==="MX"?[e=>!!e||this.$t("required_field")]:[]},billingCountry(){return this.form.billing_country},billingZipMask(){return this.form.billing_country==="CA"?"X#X #X#":"#####"},billingZipRules(){return this.form.billing_country==="CA"?[e=>!!e&&e.length===7||this.$t("required_field")]:[e=>!!e&&e.length===5||this.$t("required_field")]},companyZipMask(){return this.form.company_country==="CA"?"X#X #X#":"#####"},companyZipRules(){return this.form.company_country==="CA"?[e=>!!e&&e.length===7||this.$t("required_field")]:[e=>!!e&&e.length===5||this.$t("required_field")]},country(){return this.form.company_country},email(){return this.form.email},sameAsPrimary(){return this.form.same_as_primary}},watch:{country:function(e){e&&(this.form.company_state=null,e==="US"&&(this.companyStateOptions=g),e==="CA"&&(this.companyStateOptions=S),e==="MX"&&(this.companyStateOptions=L))},billingCountry:function(e){e&&(this.form.billing_state=null,e==="US"&&(this.billingStateOptions=g),e==="CA"&&(this.billingStateOptions=S),e==="MX"&&(this.billingStateOptions=L))},email:function(e){e&&this.emailAsId&&(this.form.username=e)},emailAsId:function(e){e&&(this.form.username=this.form.email)}},mounted(){if(localStorage.getItem("AUTH_ACCOUNT")){const e=JSON.parse(localStorage.getItem("AUTH_ACCOUNT"));this.form.account_id=e.id,this.form.company_name=e.name,this.disableCompany=!0}this.$page.props.tenant&&Object.keys(this.$page.props.tenant).length!==0?this.tenantData=this.$page.props.tenant:this.tenantData={name:"default"}},methods:{async registerUser(){try{this.loading=!0;const e=Object.fromEntries(Object.entries(this.form).filter(([s,_])=>_!==null));await H.post("/register",e).then(()=>{window.location="/login"})}catch(e){console.error(e.response.data.errors),e.response.data.errors&&this.$q.dialog({component:oe,componentProps:{errors:e.response.data.errors},parent:this})}finally{this.loading=!1}},signup(){this.$refs.signupForm.validate().then(e=>{e&&this.registerUser()})},toggleTooltip(){(this.form.password.length>0||!this.validationRule.validation)&&(this.pwdCriteriaVisible=!0)},emailValidation(e){return j(e)},passwordValidation(e){const{upper:s,special:_,num:t,validation:v}=B(e);this.validationRule={upper:s,special:_,num:t,validation:v}}}},re=e=>(J("data-v-d01d3eb0"),e=e(),W(),e),ie={class:"position-relative"},ne={key:0,src:"/img/fpg.png",style:{"max-height":"200px",margin:"auto","padding-top":"4em"}},de={class:"row"},te={class:"col q-px-sm"},ue={class:"row"},me={class:"col"},pe={class:"self-center full-width no-outline"},_e={class:"row"},fe={class:"col"},be={class:"row"},ge={class:"col q-pr-xs"},ye={class:"col q-pl-xs"},ce={class:"row"},he={class:"col q-pr-xs"},ve={class:"row"},Ve={class:"col-8 q-pr-xs"},we={class:"col q-pl-xs"},$e={class:"row"},qe={class:"col q-pr-sm"},Ce={class:"col"},Ue={class:"row q-mt-md"},Ae={class:"m-auto",style:{"max-width":"550px"}},ke=re(()=>o("b",null,"Note:",-1)),Se={class:"row q-mt-md m-auto"},Le={class:"row q-mt-md m-auto"},Pe={class:"text-secondary text-weight-bold"},Re={href:"/login",style:{"text-decoration":"underline"}},Xe={class:"text-weight-bolder"},Me={key:1,class:"col q-px-sm"},Oe={class:"row"},Ie={class:"col"},Qe={class:"self-center full-width no-outline"},Te={class:"row"},ze={class:"col-md-5 q-pr-xs"},De={class:"col q-pl-xs"},Fe={class:"row"},Ne={class:"col-md q-pr-xs"},Ze={class:"row q-mb-md"},Ee={class:"col-md-6 q-pr-xs"},He={class:"col-md-6 q-pl-xs"},je={class:"row q-mb-md"},Be={class:"col-md-6 q-pr-xs"},Ge={class:"col-md-6 q-pl-xs"},Ke={class:"row"},Je={class:"col-md-6 q-pr-xs"},We={class:"col q-px-xs"},Ye={class:"col q-pl-xs"},xe={class:"row"},el={class:"col q-pr-xs"},ll={class:"col q-pl-xs"},sl={class:"row"},ol={class:"col"},al={class:"row"},rl={class:"col"},il={class:"self-center full-width no-outline"},nl={class:"col"},dl={key:0,class:"row"},tl={class:"col-md-5 q-pr-xs"},ul={class:"col q-pl-xs"},ml={key:1,class:"row"},pl={class:"col-md q-pr-xs"},_l={key:2,class:"row q-mb-md"},fl={class:"col-6 q-pr-xs"},bl={class:"col-md-6 q-pl-xs"},gl={key:3,class:"row q-mb-md"},yl={class:"col-md-6 q-pr-xs"},cl={class:"col-md-6 q-pl-xs"},hl={key:4,class:"row"},vl={class:"col-md-6 q-pr-xs"},Vl={class:"col q-px-xs"},wl={class:"col q-pl-xs"},$l={key:5,class:"row"},ql={class:"col q-pr-xs"},Cl={class:"col q-pl-xs"},Ul={key:6,class:"row"},Al={class:"col"};function kl(e,s,_,t,v,r){const V=y("AuthFormHeader"),w=y("PwdValidationTooltip"),A=y("TelephoneInput"),O=y("GuestLayout");return d(),f(O,null,{page:n(()=>[o("div",ie,[a(M,{class:K(["absolute-center",{"auth-card":e.disableCompany,"auth-card-2":!e.disableCompany}]),flat:"",bordered:""},{default:n(()=>[a(b,{horizontal:""},{default:n(()=>[a(b,{class:"login-side_img"},{default:n(()=>[e.tenantData.name==="default"?(d(),m("img",ne)):u("",!0)]),_:1}),a(b,{class:"m-auto"},{default:n(()=>[a(V,{"form-title":"signup"}),a(G,{ref:"signupForm",class:"q-gutter-x-none q-my-md"},{default:n(()=>[o("div",de,[o("div",te,[o("div",ue,[o("div",me,[a(q,{dense:"",borderless:""},{control:n(()=>[o("div",pe,[o("b",null,p(e.$t("signup_page_title_user_info")),1)])]),_:1})])]),o("div",_e,[o("div",fe,[a(i,{modelValue:e.form.company_name,"onUpdate:modelValue":s[0]||(s[0]=l=>e.form.company_name=l),outlined:"",label:e.$t("signup_page_label_company_name"),disable:e.disableCompany,dense:"",rules:[l=>!!l||e.$t("signup_page_label_company_name")+" required"]},null,8,["modelValue","label","disable","rules"])])]),o("div",be,[o("div",ge,[a(i,{modelValue:e.form.first_name,"onUpdate:modelValue":s[1]||(s[1]=l=>e.form.first_name=l),outlined:"",label:e.$t("first_name"),dense:"",rules:[l=>!!l||e.$t("first_name")+" required"]},null,8,["modelValue","label","rules"])]),o("div",ye,[a(i,{modelValue:e.form.last_name,"onUpdate:modelValue":s[2]||(s[2]=l=>e.form.last_name=l),outlined:"",label:e.$t("last_name"),dense:"",rules:[l=>!!l||e.$t("last_name")+" required"]},null,8,["modelValue","label","rules"])])]),o("div",ce,[o("div",he,[a(i,{modelValue:e.form.email,"onUpdate:modelValue":s[3]||(s[3]=l=>e.form.email=l),outlined:"",label:e.$t("email"),dense:"",error:e.form.errors.email,"error-message":e.form.errors.email,rules:[l=>!!l||e.$t("email")+" required",r.emailValidation]},null,8,["modelValue","label","error","error-message","rules"])])]),o("div",ve,[o("div",Ve,[a(i,{modelValue:e.form.username,"onUpdate:modelValue":s[4]||(s[4]=l=>e.form.username=l),outlined:"",label:e.$t("username"),dense:"",disable:e.emailAsId,error:e.form.errors.username,"error-message":e.form.errors.username,rules:[l=>!!l||e.$t("username")+" required"]},null,8,["modelValue","label","disable","error","error-message","rules"])]),o("div",we,[a(P,{modelValue:e.emailAsId,"onUpdate:modelValue":s[5]||(s[5]=l=>e.emailAsId=l),label:e.$t("signup_page_checkbox_use_email")},null,8,["modelValue","label"])])]),o("div",$e,[o("div",qe,[a(i,{modelValue:e.form.password,"onUpdate:modelValue":s[7]||(s[7]=l=>e.form.password=l),outlined:"",type:t.isPwd?"password":"text",label:e.$t("password"),dense:"",error:e.form.errors.password&&!e.validationRule.validation,"error-message":e.form.errors.password,rules:[l=>!!l||e.$t("password")+" required",e.passwordValidatio],onFocus:r.toggleTooltip},{append:n(()=>[e.form.password.length>0?(d(),f(U,{key:0,class:"cusor-pointer",name:t.isPwd?"visibility_off":"visibility",color:e.form.errors.password&&!e.validationRule.validation?"negative":"primary",onClick:s[6]||(s[6]=l=>t.isPwd=!t.isPwd)},null,8,["name","color"])):u("",!0)]),default:n(()=>[a(w,{pwd:e.form.password,"validation-rule":e.validationRule,"pwd-validation-visible":t.pwdCriteriaVisible,"tooltip-anchor-pos":"bottom left","self-pos":"top start"},null,8,["pwd","validation-rule","pwd-validation-visible"])]),_:1},8,["modelValue","type","label","error","error-message","rules","onFocus"])]),o("div",Ce,[a(i,{modelValue:e.form.password_confirmation,"onUpdate:modelValue":s[9]||(s[9]=l=>e.form.password_confirmation=l),outlined:"",type:t.isConfirmPwd?"password":"text",label:e.$t("confirm"),dense:"",error:e.form.errors.password_confirmation,"error-message":e.form.errors.password_confirmation,rules:[l=>l===e.form.password||e.$t("signup_page_error_password_confirm")]},{append:n(()=>[e.form.password_confirmation.length>0?(d(),f(U,{key:0,class:"cusor-pointer",name:t.isConfirmPwd?"visibility_off":"visibility",color:e.form.password!==e.form.password_confirmation?"negative":"primary",onClick:s[8]||(s[8]=l=>t.isConfirmPwd=!t.isConfirmPwd)},null,8,["name","color"])):u("",!0)]),_:1},8,["modelValue","type","label","error","error-message","rules"])])]),o("div",Ue,[o("span",Ae,[ke,h("    "+p(e.$t("signup_page_note")),1)])]),o("div",Se,[a(X,{color:"grey-3","text-color":"primary",label:e.$t("signup_page_btn_sign_up"),class:"bolder-text",style:{width:"100%"},loading:e.loading,onClick:r.signup},null,8,["label","loading","onClick"])]),o("div",Le,[o("span",Pe,[o("b",null,p(e.$t("signup_page_already_have_account")),1),h("    "),o("a",Re,[o("span",Xe,p(e.$t("signup_page_btn_sign_in")),1)])])])]),e.disableCompany?u("",!0):(d(),f(C,{key:0,vertical:"",class:"q-mx-md"})),e.disableCompany?u("",!0):(d(),m("div",Me,[o("div",Oe,[o("div",Ie,[a(q,{dense:"",borderless:""},{control:n(()=>[o("div",Qe,[o("b",null,p(e.$t("signup_page_title_company_info")),1)])]),_:1})])]),o("div",Te,[o("div",ze,[a(c,{modelValue:e.form.company_country,"onUpdate:modelValue":s[10]||(s[10]=l=>e.form.company_country=l),outlined:"",dense:"",label:e.$t("address_country"),autocomplete:"off","emit-value":"","map-options":"",options:[{label:e.$t("country_us"),value:"US"},{label:e.$t("country_ca"),value:"CA"},{label:e.$t("country_mx"),value:"MX"}],rules:[l=>!!l||e.$t("required_field")]},null,8,["modelValue","label","options","rules"])]),o("div",De,[a(A,{label:e.$t("signup_page_label_primary_contact_phone"),phone:e.form.company_phone,dense:!0,required:!0,"default-country-code":e.form.company_country,onUpdate:s[11]||(s[11]=l=>e.form.company_phone=l.phone)},null,8,["label","phone","default-country-code"])])]),o("div",Fe,[o("div",Ne,[a(i,{modelValue:e.form.company_address_1,"onUpdate:modelValue":s[12]||(s[12]=l=>e.form.company_address_1=l),name:"company_address",outlined:"",dense:"",label:r.address1Label,rules:[l=>!!l||e.$t("required_field")]},null,8,["modelValue","label","rules"])])]),o("div",Ze,[o("div",Ee,[a(i,{modelValue:e.form.company_address_2,"onUpdate:modelValue":s[13]||(s[13]=l=>e.form.company_address_2=l),outlined:"",dense:"",label:r.address2Label,rules:r.address2Rules},null,8,["modelValue","label","rules"])]),o("div",He,[a(i,{modelValue:e.form.company_address_3,"onUpdate:modelValue":s[14]||(s[14]=l=>e.form.company_address_3=l),outlined:"",dense:"",label:r.address3Label,rules:r.address3Rules},null,8,["modelValue","label","rules"])])]),o("div",je,[o("div",Be,[a(i,{modelValue:e.form.company_address_4,"onUpdate:modelValue":s[15]||(s[15]=l=>e.form.company_address_4=l),outlined:"",dense:"",label:r.address4Label,rules:r.address4Rules},null,8,["modelValue","label","rules"])]),o("div",Ge,[a(i,{modelValue:e.form.company_address_5,"onUpdate:modelValue":s[16]||(s[16]=l=>e.form.company_address_5=l),outlined:"",dense:"",label:r.address5Label},null,8,["modelValue","label"])])]),o("div",Ke,[o("div",Je,[a(i,{modelValue:e.form.company_city,"onUpdate:modelValue":s[17]||(s[17]=l=>e.form.company_city=l),name:"company_city",outlined:"",label:e.$t("address_city"),dense:"",rules:[l=>!!l||e.$t("required_field")]},null,8,["modelValue","label","rules"])]),o("div",We,[a(c,{modelValue:e.form.company_state,"onUpdate:modelValue":s[18]||(s[18]=l=>e.form.company_state=l),name:"company_state",outlined:"",label:e.form.company_country==="CA"?e.$t("address_province"):e.$t("address_state"),dense:"","no-error-icon":"",options:e.companyStateOptions,rules:[l=>!!l&&l.length===2||e.$t("required_field")]},null,8,["modelValue","label","options","rules"])]),o("div",Ye,[a(i,{modelValue:e.form.company_zip,"onUpdate:modelValue":s[19]||(s[19]=l=>e.form.company_zip=l),outlined:"",label:e.form.company_country==="US"?e.$t("address_zipcode"):e.$t("address_postal_code"),dense:"","no-error-icon":"",mask:r.companyZipMask,rules:r.companyZipRules},null,8,["modelValue","label","mask","rules"])])]),o("div",xe,[o("div",el,[a(i,{modelValue:e.form.company_first_name,"onUpdate:modelValue":s[20]||(s[20]=l=>e.form.company_first_name=l),outlined:"",label:e.$t("signup_page_label_primary_contact_first_name"),dense:"",rules:[l=>!!l||e.$t("required_field")]},null,8,["modelValue","label","rules"])]),o("div",ll,[a(i,{modelValue:e.form.company_last_name,"onUpdate:modelValue":s[21]||(s[21]=l=>e.form.company_last_name=l),outlined:"",label:e.$t("signup_page_label_primary_contact_last_name"),dense:"",rules:[l=>!!l||e.$t("required_field")]},null,8,["modelValue","label","rules"])])]),o("div",sl,[o("div",ol,[a(i,{modelValue:e.form.company_email,"onUpdate:modelValue":s[22]||(s[22]=l=>e.form.company_email=l),outlined:"",label:e.$t("signup_page_label_primary_contact_email"),dense:"",error:e.form.errors.company_email,"error-message":e.form.errors.company_email,rules:[l=>!!l||e.$t("required_field"),r.emailValidation]},null,8,["modelValue","label","error","error-message","rules"])])]),o("div",al,[o("div",rl,[a(q,{dense:"",borderless:""},{control:n(()=>[o("div",il,[o("b",null,p(e.$t("signup_page_title_accounting_info")),1)])]),_:1})]),o("div",nl,[a(P,{modelValue:e.form.same_as_primary,"onUpdate:modelValue":s[23]||(s[23]=l=>e.form.same_as_primary=l),label:e.$t("signup_page_checkbox_same_as_company")},null,8,["modelValue","label"])])]),r.sameAsPrimary?u("",!0):(d(),m("div",dl,[o("div",tl,[a(c,{modelValue:e.form.billing_country,"onUpdate:modelValue":s[24]||(s[24]=l=>e.form.billing_country=l),outlined:"",dense:"",label:e.$t("address_country"),autocomplete:"off","emit-value":"","map-options":"",options:[{label:e.$t("country_us"),value:"US"},{label:e.$t("country_ca"),value:"CA"},{label:e.$t("country_mx"),value:"MX"}],rules:[l=>!!l||e.$t("required_field")]},null,8,["modelValue","label","options","rules"])]),o("div",ul,[a(A,{label:e.$t("signup_page_label_accounting_contact_phone"),phone:e.form.billing_phone,dense:!0,required:!0,"default-country-code":e.form.billing_country,onUpdate:s[25]||(s[25]=l=>e.form.billing_phone=l.phone)},null,8,["label","phone","default-country-code"])])])),r.sameAsPrimary?u("",!0):(d(),m("div",ml,[o("div",pl,[a(i,{modelValue:e.form.billing_address_1,"onUpdate:modelValue":s[26]||(s[26]=l=>e.form.billing_address_1=l),name:"billing_address",outlined:"",dense:"",label:r.billingAddress1Label,rules:[l=>!!l||e.$t("required_field")]},null,8,["modelValue","label","rules"])])])),r.sameAsPrimary?u("",!0):(d(),m("div",_l,[o("div",fl,[a(i,{modelValue:e.form.billing_address_2,"onUpdate:modelValue":s[27]||(s[27]=l=>e.form.billing_address_2=l),outlined:"",dense:"",label:r.billingAddress2Label,rules:r.billingAddress2Rules},null,8,["modelValue","label","rules"])]),o("div",bl,[a(i,{modelValue:e.form.billing_address_3,"onUpdate:modelValue":s[28]||(s[28]=l=>e.form.billing_address_3=l),outlined:"",dense:"",label:r.billingAddress3Label,rules:r.billingAddress3Rules},null,8,["modelValue","label","rules"])])])),r.sameAsPrimary?u("",!0):(d(),m("div",gl,[o("div",yl,[a(i,{modelValue:e.form.billing_address_4,"onUpdate:modelValue":s[29]||(s[29]=l=>e.form.billing_address_4=l),outlined:"",dense:"",label:r.billingAddress4Label,rules:r.billingAddress4Rules},null,8,["modelValue","label","rules"])]),o("div",cl,[a(i,{modelValue:e.form.billing_address_5,"onUpdate:modelValue":s[30]||(s[30]=l=>e.form.billing_address_5=l),outlined:"",dense:"",label:r.billingAddress5Label},null,8,["modelValue","label"])])])),r.sameAsPrimary?u("",!0):(d(),m("div",hl,[o("div",vl,[a(i,{modelValue:e.form.billing_city,"onUpdate:modelValue":s[31]||(s[31]=l=>e.form.billing_city=l),name:"billing_city",outlined:"",label:e.$t("address_city"),dense:"",rules:[l=>!!l||e.$t("required_field")]},null,8,["modelValue","label","rules"])]),o("div",Vl,[a(c,{modelValue:e.form.billing_state,"onUpdate:modelValue":s[32]||(s[32]=l=>e.form.billing_state=l),name:"billing_state",outlined:"",label:e.form.billing_country==="CA"?e.$t("address_province"):e.$t("address_state"),dense:"","no-error-icon":"",options:e.billingStateOptions,rules:[l=>!!l&&l.length===2||e.$t("required_field")]},null,8,["modelValue","label","options","rules"])]),o("div",wl,[a(i,{modelValue:e.form.billing_zip,"onUpdate:modelValue":s[33]||(s[33]=l=>e.form.billing_zip=l),outlined:"",label:e.form.billing_country==="US"?e.$t("address_zipcode"):e.$t("address_postal_code"),dense:"","no-error-icon":"",mask:r.billingZipMask,rules:r.billingZipRules},null,8,["modelValue","label","mask","rules"])])])),r.sameAsPrimary?u("",!0):(d(),m("div",$l,[o("div",ql,[a(i,{modelValue:e.form.billing_first_name,"onUpdate:modelValue":s[34]||(s[34]=l=>e.form.billing_first_name=l),outlined:"",label:e.$t("signup_page_label_accounting_contact_first_name"),dense:"",rules:[l=>!!l||e.$t("required_field")]},null,8,["modelValue","label","rules"])]),o("div",Cl,[a(i,{modelValue:e.form.billing_last_name,"onUpdate:modelValue":s[35]||(s[35]=l=>e.form.billing_last_name=l),outlined:"",label:e.$t("signup_page_label_accounting_contact_last_name"),dense:"",rules:[l=>!!l||e.$t("required_field")]},null,8,["modelValue","label","rules"])])])),r.sameAsPrimary?u("",!0):(d(),m("div",Ul,[o("div",Al,[a(i,{modelValue:e.form.billing_email,"onUpdate:modelValue":s[36]||(s[36]=l=>e.form.billing_email=l),outlined:"",label:e.$t("signup_page_label_accounting_contact_email"),dense:"",error:e.form.errors.billing_email,"error-message":e.form.errors.billing_email,rules:[l=>!!l||e.$t("required_field"),r.emailValidation]},null,8,["modelValue","label","error","error-message","rules"])])]))]))])]),_:1},512)]),_:1})]),_:1})]),_:1},8,["class"])])]),_:1})}const Xl=R(ae,[["render",kl],["__scopeId","data-v-d01d3eb0"]]);export{Xl as default};
