PageSourceSearch

https://rhai.ai/assets/NsPress-B5R6GbP6.js

js rhai.ai collected 2026-10-05 14:42:25 UTC 6,845 bytes, 1 lines download raw bytes

1import{r as t,j as e,m as y,B as R,L as C}from"./index-Bb1yq-wp.js";import{u as T,i as k,E as z,a as H,P,n as V}from"./novo-site-comercial-api-B4ROC9IT.js";import{N as F}from"./NsFooter-C7mTVp2S.js";/* empty css                  */const M=1,U="849b89dd-c253-4ea8-8e37-56b29e218223",D="db4716c0-0a90-4746-a0e3-0e8fc7874165",q="/__l5e/assets-v1/849b89dd-c253-4ea8-8e37-56b29e218223/rhai_rp_contact.png",B="a/v1/db4716c0-0a90-4746-a0e3-0e8fc7874165/849b89dd-c253-4ea8-8e37-56b29e218223/rhai_rp_contact.png",G="rhai_rp_contact.png",O=1661169,W="image/png",Y="2026-09-23T21:27:56Z",Z={version:M,asset_id:U,project_id:D,url:q,r2_key:B,original_filename:G,size:O,content_type:W,created_at:Y},$="0x4AAAAAAFBjNhZJpeRwPRLS",w="https://challenges.cloudflare.com/turnstile/v0/api.js?render=explicit";function J(){const r=window;return r.turnstile?Promise.resolve(r.turnstile):new Promise((f,m)=>{let s=document.querySelector(`script[src="${w}"]`);s||(s=document.createElement("script"),s.src=w,s.async=!0,s.defer=!0,document.head.appendChild(s)),s.addEventListener("load",()=>r.turnstile?f(r.turnstile):m(new Error("turnstile"))),s.addEventListener("error",()=>m(new Error("turnstile")))})}const K=new URL(Z.url,"https://lovable-curator-ai.lovable.app").toString(),S=(r=0)=>({duration:.55,ease:[.4,0,.2,1],delay:r});function Q({compact:r}){return e.jsxs(y.header,{initial:{opacity:0}
1,animate:{opacity:1},transition:S(),className:`ns-header${r?" is-compact":""}`,children:[e.jsx(C,{to:"/","aria-label":"RHAI — voltar ao início",children:e.jsx("img",{className:"ns-header-logo",src:"/site-v2/brand/rhai-logo.webp",width:400,height:127,alt:"RHAI"})}),e.jsx("a",{className:"ns-client-access",href:"/console/login",children:"Acesso de clientes"})]})}const X={assunto:"imprensa",nome_pessoa:"",nome_organizacao:"",email:"",telefone:"",mensagem:"",website:""};function te(){const r=T(),[f,m]=t.useState(!1),[s,i]=t.useState(X),[x,j]=t.useState(!1),[b,o]=t.useState(null),[d,A]=t.useState(!1),[_,c]=t.useState(null),v=t.useRef(null),l=t.useRef(null),u=t.useRef(null);t.useEffect(()=>{document.documentElement.classList.add("ns-document");const n=()=>m(window.scrollY>0);return n(),window.addEventListener("scroll",n,{passive:!0}),()=>{window.removeEventListener("scroll",n),document.documentElement.classList.remove("ns-document")}},[]),t.useEffect(()=>{if(d)return;let n=!1;return J().then(a=>{n||!v.current||(u.current=a,l.current=a.render(v.current,{sitekey:$,theme:"light",language:"pt-br",callback:p=>c(p),"expired-callback":()=>c(null),"timeout-callback":()=>c(null),"error-callback":()=>(c(null),!0)}))}).catch(()=>{n||o("Não foi possível carregar a verificação de segurança. Recarregue a página e tente novamente.")}),()=>{n=!0,u.current&&l.current&&u.current.remove(l.current),l.current=null}},[d]);const I=()=>{c(null),u.current&&l.current&&u.current.reset(l.current)},L=async n=>{if(n.preventDefault(),x)return;const a=s.nome_pessoa.trim(),p=s.nome_organizacao.trim(),h=s.email.trim(),g=s.telefone.trim(),N=s.mensagem.trim();if(!a)return o("Informe seu nome.");if(!p)return o("Informe o veículo ou a organização.");
1if(!h&&!g)return o("Informe um e-mail ou telefone para contato.");if(h&&!k(h))return o(z);if(g&&!H(g))return o(P);if(!N)return o("Escreva sua mensagem.");if(!_)return o("Aguarde a verificação de segurança ser concluída e tente novamente.");o(null),j(!0);const E=await V.contactCreate({origem:s.assunto,nome_pessoa:a,nome_organizacao:p,email:h||null,telefone:g||null,telefone_whatsapp:null,linkedin:null,mensagem:N,turnstile_token:_,website:s.website});if(j(!1),I(),!E.success){o(E.message||"Não foi possível enviar sua mensagem agora.");return}A(!0)};return e.jsx("div",{className:"ns-root nsp-root",children:e.jsxs(y.div,{className:"ns-page",initial:r?{opacity:1}:{opacity:0},animate:{opacity:1},transition:S(),children:[e.jsx(Q,{compact:f}),e.jsxs("section",{className:"nsp-hero","aria-labelledby":"nsp-hero-title",children:[e.jsx("img",{className:"nsp-hero-image",src:K,alt:"","aria-hidden":"true"}),e.jsxs("div",{className:"nsp-hero-content",children:[e.jsx("h1",{id:"nsp-hero-title",children:"Uma boa conversa pode virar notícia."}),e.jsx("p",{children:"Quer saber mais sobre a RHAI, conversar com a nossa equipe ou levar essa história para mais gente? Este é o lugar."})]})]}),!d&&e.jsxs("section",{className:"nsp-message","aria-labelledby":"nsp-message-title",children:[e.jsxs("div",{className:"nsp-message-copy",children:[e.jsx("h2",{id:"nsp-message-title",children:"Vamos conversar?"}),e.jsx("p",{children:"Imprensa, entrevistas, informações sobre a RHAI ou outros assuntos. Conte pra gente o que você precisa e deixe um contato para continuarmos a conversa."})]}),e.jsxs("form",{className:"nsp-form",onSubmit:L,noValidate:!0,children:[e.jsx("h3",{children:"Fale com a RHAI"}),e.jsxs("label",{className:"nsp-input nsp-input--wide",children:[e.jsx("span",{children:"Assunto"}),e.jsxs("select",{value:s.assunto,onChange:n=>i(a=>({...a,assunto:n.target.value})),children:[e.jsx("option",{value:"imprensa",children:"Imprensa"}),e.jsx("option",{value:"contato_geral",children:"Contato geral"})]})]}),e.jsxs("label",{className:"nsp-input",children:[e.jsx("span",{children:"Seu nome"}),e.jsx("input",{type:"text",value:s.nome_pessoa,maxLength:120,onChange:n=>i(a=>({...a,nome_pessoa:n.target.value}))})]}),e.jsxs("label",{className:"nsp-input",children:[e.jsx("span",{children:"Veículo / organização"}),e.jsx("input",{type:"text",value:s.nome_organizacao,maxLength:160,onChange:n=>i(a=>({...a,nome_organizacao:n.target.value}))})]}),e.jsxs("label",{className:"nsp-input",children:[e.jsx("span",{children:"E-mail"}),e.jsx("input",{type:"email",value:s.email,maxLength:255,onChange:n=>i(a=>({...a,email:n.target.value}))})]}),e.jsxs("label",{className:"nsp-input",children:[e.jsx("span",{children:"Telefone / WhatsApp"}),e.jsx("input",{type:"tel",value:s.telefone,maxLength:40,onChange:n=>i(a=>({...a,telefone:n.target.value}))})]}),e.jsxs("label",{className:"nsp-input nsp-input--wide",children:[e.jsx("span",{children:"Sua mensagem"}),e.jsx("textarea",{value:s.mensagem,maxLength:2e3,rows:6,onChange:n=>i(a=>({...a,mensagem:n.target.value}))})]}),e.jsx("div",{className:"nsp-honeypot","aria-hidden":"true",children:e.jsxs("label",{children:["Website",e.jsx("input",{type:"text",tabIndex:-1,autoComplete:"off",value:s.website,onChange:n=>i(a=>({...a,website:n.target.value}))})]})}),e.jsx("div",{className:"nsp-turnstile",ref:v}),b&&e.jsx("p",{className:"nsp-alert",children:b}),e.jsx(R,{type:"submit",className:"nsp-submit",disabled:x,children:x?"Enviando...":"Enviar mensagem"})]})]}),d&&e.jsx("section",{className:"nsp-message nsp-message--done","aria-live":"polite",children:e.jsx("h2",{children:"Mensagem recebida! Obrigado por entrar em contato."})}),e.jsx(F,{})]})})}export{te as NsPress,te as default};

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.