1!function(){try{var a="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},e=(new a.Error).stack;e&&(a._sentryDebugIds=a._sentryDebugIds||{},a._sentryDebugIds[e]="9ce0312b-a48e-4a00-9552-493425d1ac1d",a._sentryDebugIdIdentifier="sentry-dbid-9ce0312b-a48e-4a00-9552-493425d1ac1d")}catch(a){}}(),(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[1299],{31299:(a,e,r)=>{"use strict";r.r(e),r.d(e,{default:()=>C});var n=r(19962),i=r(65394),s=r(77100),o=r(28621),t=r(54409),l=r.n(t),c=r(57454),u=r(13789),d=r(3240),m=r(36761),p=r(91070),_=r(97574),b=r(21893),h=r.n(b);let y=(0,i.memo)(function(a){return(0,n.jsx)("div",{...a,children:(0,n.jsx)(h(),{width:38,height:26,quality:100,objectFit:"cover",alt:"\xcdcone da bandeira do Brasil",src:"/public-web/assets/icons/bandeira-do-brasil.png"})})});var g=r(36189),v=r(27226),f=r(98683);let x=["Afghanistan","Albania","Algeria","Andorra","Angola","Antigua and Barbuda","Argentina","Armenia","Australia","Austria","Azerbaijan","Bahamas","Bahrain","Bangladesh","Barbados","Belarus","Belgium","Belize","Benin","Bhutan","Bolivia","Bosnia and Herzegovina","Botswana","Brazil","Brunei","Bulgaria","Burkina Faso","Burundi","C\xf4te d'Ivoire","Cabo Verde","Cambodia","Cameroon","Canada","Chad","Chile","China","Colombia","Comoros","Costa Rica","Croatia","Cuba","Cyprus","Denmark","Djibouti","Dominica","Dominican Republic","Ecuador","Egypt","El Salvador","Equatorial Guinea","Eritrea","Estonia","Ethiopia","Fiji","Finland","France","Gabon","Gambia","Georgia","Germany","Ghana","Greece","Grenada","Guatemala","Guinea","Guinea-Bissau","Guyana","Haiti","Holy See","Honduras","Hungary","Iceland","India","Indonesia","Iran","Iraq","Ireland","Israel","Italy","Jamaica","Japan","Jordan","Kazakhstan","Kenya","Kiribati","Kuwait","Kyrgyzstan","Laos","Latvia","Lebanon","Lesotho","Liberia","Libya","Liechtenstein","Lithuania","Luxembourg","Madagascar","Malawi","Malaysia","Maldives","Mali","Malta","Marshall Islands","Mauritania","Mauritius","Mexico","Micronesia","Moldova","Monaco","Mongolia","Montenegro","Morocco","Mozambique","Namibia","Nauru","Nepal","Netherlands","New Zealand","Nicaragua","Niger","Nigeria","North Korea","North Macedonia","Norway","Oman","Pakistan","Palau","Palestine State","Panama","Papua New Guinea","Paraguay","Peru","Philippines","Poland","Portugal","Qatar","Romania","Russia","Rwanda","Saint Kitts and Nevis","Saint Lucia","Samoa","San Marino","Sao Tome and Principe","Saudi Arabia","Senegal","Serbia","Seychelles","Sierra Leone","Singapore","Slovakia","Slovenia","Solomon Islands","Somalia","South Africa","South Korea","South Sudan","Spain","Sri Lanka","Sudan","Suriname","Sweden","Switzerland","Syria","Tajikistan","Tanzania","Thailand","Timor-Leste","Togo","Tonga","Trinidad and Tobago","Tunisia","Turkey","Turkmenistan","Tuvalu","Uganda","Ukraine","United Arab Emirates","United Kingdom","Uruguay","Uzbekistan","Vanuatu","Venezuela","Vietnam","Yemen","Zambia","Zimbabwe"];var S=r(93165),N=r(6988),j=r(59111),w=r.n(j);let C=(0,i.memo)(function(a){var e,r,t,b,h;let{modal:j,submitted:C,handleSubmitted:T,setSubmitted:A,className:B,...k}=a,[M,E]=(0,i.useState)(""),[z,I]=(0,i.useState)(void 0),q=(0,i.useContext)(g.JV),L=new s.A,P=L.get("hubspotutk"),F={resolver:(0,N.t)(v.Fd)},{register:G,handleSubmit:W,formState:{errors:D,isSubmitting:R},control:U,reset:K}=(0,o.mN)(F);async function O(a){var e;let r={firstname:{name:"firstname",value:a.firstname},phone:{name:"phone",value:a.phone},pre_aprovacao_perfil:{name:"pre_aprovacao_perfil",value:"Brasileiro no Exterior - Pais: ".concat(a.pre_aprovacao_perfil)},pre_aprovacao_renda:{name:"pre_aprovacao_renda",value:a.pre_aprovacao_renda},channel:{name:"canal_de_contato",value:"Formulario Site"},interest:{name:"apto_de_interesse_atual",value:"Credito imobiliario"},context:{hutk:P||"",pageName:null==(e=document)?void 0:e.title,pageUri:window.location.href?window.location.href:"",ipAddress:q||"",ppc_source:L.get("imb_ppc")||null,referer:L.get("imb_lp_url")||null}};P&&(0,f.lb)(P);try{if(!(await fetch("/api/imobles-web/rocket/simulator-brazilian-abroad",{method:"POST",body:JSON.stringify(r),headers:{Accept:"application/json","Content-Type":"application/json"}})).ok)throw Error("Error trying to make a request to /api/imobles-web/rocket/simulator-brazilian-abroad.");A(!0),I(a.firstname),K()}catch(a){E("Erro inesperado, tente novamente em alguns minutos")}}return(0,n.jsx)(n.Fragment,{children:C?(0,n.jsx)(u.A,{modal:j,handleSubmitted:T,formSubmittedWrapperClass:w().formWrapper,customScrollableWrapperClass:w().contentWrapper,customOptionsClassName:w().customOptions,modalContentTitle:"Saiba exatamente quanto e com quais taxas voc\xea consegue financiar, mesmo sem renda fixa",userName:z}):(0,n.jsxs)("form",{className:l()(w().form,B),onSubmit:W(O),...k,children:[(0,n.jsxs)("div",{className:w().content,children:[(0,n.jsx)("h5",{className:w().contentTitle,children:"Saiba exatamente quanto e com quais taxas voc\xea consegue financiar, mesmo sem renda fixa"}),(0,n.jsxs)("div",{className:w().inputs,children:[(0,n.jsx)("h5",{className:w().title,children:"Sua renda estimada"}),(0,n.jsxs)("div",{className:l()(w().wrapper,w().currencyContainer),children:[(0,n.jsxs)("div",{className:w().currency,children:[(0,n.jsx)("span",{className:w().label,children:"Moeda"}),(0,n.jsxs)("div",{className:w().currencySymbol,children:[(0,n.jsx)(y,{className:w().brazilFlag}),"R$ (BRL)"]})]}),(0,n.jsx)(m.A,{prefix:"R$ ",minValue:0,maxLength:7,minLength:1,maxValue:1e6,label:"Valor mensal",placeholder:"R$ 0.000.000",error:null==D||null==(e=D.pre_aprovacao_renda)?void 0:e.message,register:G("pre_aprovacao_renda")})]}),(0,n.jsx)("span",{className:l()(w().error,w().errorCurrency),children:null==D||null==(r=D.pre_aprovacao_renda)?void 0:r.message}),(0,n.jsxs)("div",{className:w().wrapper,children:[(0,n.jsx)(_.A,{error:null==D||null==(t=D.pre_aprovacao_perfil)?void 0:t.message,options:x,register:G("pre_aprovacao_perfil"),placeholder:"Em qual pa\xeds voc\xea mora?","data-testid":"country"}),(0,n.jsx)("span",{className:w().error,children:null==D||null==(b=D.pre_aprovacao_perfil)?void 0:b.message})]}),(0,n.jsx)("div",{className:w().wrapper,children:(0,n.jsx)(d.default,{label:"Nome",placeholder:"Digite seu nome",register:G("firstname"),error:null==D||null==(h=D.firstname)?void 0:h.message})}),(0,n.jsx)("div",{className:w().wrapper,children:(0,n.jsx)(o.xI,{name:"phone",control:U,render:a=>{var e;
1let{field:{onChange:r,value:i}}=a;return(0,n.jsx)(p.default,{label:"Telefone",error:null==D||null==(e=D.phone)?void 0:e.message,placeholder:"(00) 00000-0000",preferredCountries:S.A,register:G("phone"),onChange:r,value:i})}})})]})]}),(0,n.jsx)("div",{className:w().buttonWrapper,children:(0,n.jsx)(c.A,{className:w().button,errorMessage:M,isSubmitting:R,text:"Confirmar e finalizar",id:"gtm-finance-real-estate-simulator-brazilian-abroad"})})]})})})},59111:a=>{a.exports={form:"styles_form__S5nwz",modalTitle:"styles_modalTitle__3QUFa",inputs:"styles_inputs__c7h9q",contentTitle:"styles_contentTitle__1CLiH",title:"styles_title__sSFtS",currencyContainer:"styles_currencyContainer__ydOjf",currency:"styles_currency__qFbo_",label:"styles_label__CZ7PH",currencySymbol:"styles_currencySymbol__m8q4a",brazilFlag:"styles_brazilFlag__g9YBN",wrapper:"styles_wrapper__W86B6",error:"styles_error__De5z9",errorCurrency:"styles_errorCurrency___xsA8",buttonWrapper:"styles_buttonWrapper__nvnjU",button:"styles_button__p4842",content:"styles_content__Oi2UW utils_scrollbar__PJlYT utils_scrollbarTrack__AEAM8 utils_scrollbarThumb__fqpZ4",contentWrapper:"styles_contentWrapper__XxRqh",customOptions:"styles_customOptions__1dTS_"}},68734:a=>{a.exports={wrapper:"styles_wrapper__3Y2dv",select:"styles_select__j9Y8f",selectError:"styles_selectError__NfsIj",error:"styles_error__xqHut"}},97574:(a,e,r)=>{"use strict";r.d(e,{A:()=>c});var n=r(19962),i=r(65394),s=r(54409),o=r.n(s),t=r(68734),l=r.n(t);let c=(0,i.memo)(function(a){let{error:e,options:r,disabled:i,placeholder:s,register:t,className:c,classNameError:u,...d}=a;return(0,n.jsxs)("div",{className:l().wrapper,children:[(0,n.jsxs)("select",{disabled:i,className:o()(l().select,c,{[l().selectError]:void 0!==e}),"aria-label":t.name,...t,...d,children:[(0,n.jsx)("option",{value:"",children:s}),null==r?void 0:r.map(a=>(0,n.jsx)("option",{value:a,children:a},a))]}),e&&"Em qual pa\xeds voc\xea mora?"!==s&&(0,n.jsx)("p",{className:o()(l().error,u),"data-aos-delay":"50","data-aos":"fade-right",children:e})]})})}}]);
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.