From 37e1a5a935b47e2170d20cb2d753ce37a12ded09 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9rgio=20Rafael=20Siqueira?= Date: Tue, 29 Apr 2025 15:46:14 -0300 Subject: [PATCH] update contact --- superpage/src/components/Accordion/Item.astro | 3 +- superpage/src/components/Course/Cert.astro | 2 +- superpage/src/components/Course/Contact.astro | 18 ---- superpage/src/components/Course/Contact.jsx | 100 +++++++++--------- .../src/components/Course/Features.astro | 2 +- .../src/components/Course/HeaderNav.astro | 14 ++- superpage/src/components/Course/Modules.astro | 2 +- superpage/src/components/Course/Plans.astro | 21 +++- superpage/src/components/Course/index.ts | 1 - .../content/courses/cipa-grau-de-risco-1.mdx | 3 - .../content/courses/cipa-grau-de-risco-2.mdx | 3 - .../content/courses/cipa-grau-de-risco-3.mdx | 3 - .../content/courses/cipa-grau-de-risco-4.mdx | 3 - superpage/src/content/courses/cipa.mdx | 1 - .../content/courses/combate-a-incendio.mdx | 3 - superpage/src/content/courses/lei-lucas.mdx | 5 +- .../content/courses/loto-lockout-e-tagout.md | 2 - .../courses/noes-em-primeiros-socorros.md | 2 - .../nr-18-plataforma-de-trabalho-aereo.mdx | 3 - superpage/src/icons/arrow-up.svg | 3 + superpage/src/layouts/Layout.astro | 21 ++-- superpage/src/pages/[slug].astro | 3 +- superpage/src/pages/_components/Stats.astro | 11 ++ superpage/src/pages/index.astro | 3 + 24 files changed, 119 insertions(+), 113 deletions(-) delete mode 100644 superpage/src/components/Course/Contact.astro create mode 100644 superpage/src/icons/arrow-up.svg create mode 100644 superpage/src/pages/_components/Stats.astro diff --git a/superpage/src/components/Accordion/Item.astro b/superpage/src/components/Accordion/Item.astro index 366e249..62f82b2 100644 --- a/superpage/src/components/Accordion/Item.astro +++ b/superpage/src/components/Accordion/Item.astro @@ -1,7 +1,6 @@
diff --git a/superpage/src/components/Course/Cert.astro b/superpage/src/components/Course/Cert.astro index f199f40..4992a88 100644 --- a/superpage/src/components/Course/Cert.astro +++ b/superpage/src/components/Course/Cert.astro @@ -3,7 +3,7 @@ import { Icon } from "astro-icon/components"; import Container from "~/components/Container.astro"; --- - +
diff --git a/superpage/src/components/Course/Contact.astro b/superpage/src/components/Course/Contact.astro deleted file mode 100644 index 5224030..0000000 --- a/superpage/src/components/Course/Contact.astro +++ /dev/null @@ -1,18 +0,0 @@ ---- -import Container from "~/components/Container.astro"; -import Form from "./Contact.jsx"; ---- - - -
-
-

Fale conosco

-

- Tem uma necessidade mais específica ou gostaria de agendar uma - demonstração da nossa plataforma? Entre em contato conosco. -

-
- -
-
-
diff --git a/superpage/src/components/Course/Contact.jsx b/superpage/src/components/Course/Contact.jsx index beb479f..9e7c465 100644 --- a/superpage/src/components/Course/Contact.jsx +++ b/superpage/src/components/Course/Contact.jsx @@ -10,6 +10,8 @@ const schema = z.object({ .string() .nonempty({ message: "Deve preencher o email" }) .email({ message: "Deve ser um email válido" }), + telephone: z.string().nonempty({ message: "Deve preencher o telefone" }), + orgname: z.string().nonempty({ message: "Deve preencher a empresa" }), message: z.string().nonempty({ message: "Deve preencher a mensagem" }), }); @@ -23,7 +25,7 @@ export default function Contact() { action="https://n8n.eduseg.com.br/webhook/a377b3e0-b159-4536-98ab-e13822b60562" onSuccess={() => reset()} control={control} - className="flex flex-col gap-2.5" + className="flex flex-col gap-3" > {formState.isSubmitSuccessful && (

@@ -31,44 +33,56 @@ export default function Contact() {

)} -
- + + {formState.errors.name?.message} -
+ -
- + + {formState.errors.email?.message} -
+ -
- - {formState.errors.message?.message} -
+ + + {formState.errors.telephone?.message} + + + + + {formState.errors.orgname?.message} + + + + + {formState.errors.message?.message} + @@ -79,33 +93,23 @@ export default function Contact() { export function Input({ as = "input", className, ...props }) { return createElement(as, { className: clsx( - "bg-white/10 focus:bg-white focus:text-black rounded-xl p-4 w-full focus:outline-0 transition duration-150", - "aria-invalid:outline-2 aria-invalid:outline-red-600", + "bg-white/5 focus:bg-white/15 rounded-lg p-3 w-full border border-white/10 focus:border-lime-400 focus:outline-0 transition", + "placeholder-white/70", + "aria-invalid:border-red-600", className, ), ...props, }); } -function Label({ children, className }) { - return ( - - ); +function Control({ children, className }) { + return ; } function Error({ children, className }) { if (children) { return ( -

- {children} -

+

{children}

); } diff --git a/superpage/src/components/Course/Features.astro b/superpage/src/components/Course/Features.astro index 1d40cfa..7df3420 100644 --- a/superpage/src/components/Course/Features.astro +++ b/superpage/src/components/Course/Features.astro @@ -5,7 +5,7 @@ import mulherdenegocios from "~/assets/mulher-de-negocios.png"; import homemdenegocios from "~/assets/homem-de-negocios.png"; --- - +