diff --git a/certs/cert.html b/certs/cert.html index 9506900..87838d8 100644 --- a/certs/cert.html +++ b/certs/cert.html @@ -1,8 +1,11 @@ + Bon de commande + + diff --git a/certs/cert.pdf b/certs/cert.pdf index d4f0955..23056b7 100644 Binary files a/certs/cert.pdf and b/certs/cert.pdf differ diff --git a/superpage/src/components/Course/Contact.jsx b/superpage/src/components/Course/Contact.jsx index 275305d..bbf1ad7 100644 --- a/superpage/src/components/Course/Contact.jsx +++ b/superpage/src/components/Course/Contact.jsx @@ -27,10 +27,10 @@ export default function Contact({ url }) { setValue("solution", e.detail); }; - window.addEventListener("custom_event:solution", handler); + window.addEventListener("custom_event:react_form", handler); return () => { - window.removeEventListener("custom_event:solution", handler); + window.removeEventListener("custom_event:react_form", handler); }; }, [setValue]); diff --git a/superpage/src/components/Course/Solutions.astro b/superpage/src/components/Course/Solutions.astro index aecfdf7..cfc52d7 100644 --- a/superpage/src/components/Course/Solutions.astro +++ b/superpage/src/components/Course/Solutions.astro @@ -2,7 +2,6 @@ import Container from "~/components/Container.astro"; import Contact from "./Contact.jsx"; import Modal from "~/components/Modal.astro"; -import { Icon } from "astro-icon/components"; --- {/* Modal */} @@ -26,7 +25,7 @@ import { Icon } from "astro-icon/components"; class="snap-center flex-shrink-0 max-lg:w-full bg-white/5 hover:scale-105 hover:bg-white/10 border border-white/15 p-4 lg:p-10 rounded-xl flex flex-col space-y-5 transform transition duration-200" >

EDUSEG® Flexível

@@ -57,7 +56,7 @@ import { Icon } from "astro-icon/components"; class="snap-center flex-shrink-0 max-lg:w-full bg-white/5 hover:scale-105 hover:bg-white/10 border border-white/15 p-4 lg:p-10 rounded-xl flex flex-col space-y-5 transform transition duration-200" >

EDUSEG® In-Company

@@ -89,7 +88,7 @@ import { Icon } from "astro-icon/components"; class="snap-center flex-shrink-0 max-lg:w-full bg-white/5 hover:scale-105 hover:bg-white/10 border border-white/15 p-4 lg:p-10 rounded-xl flex flex-col space-y-5 transform transition duration-200" >

EDUSEG® Conteúdo

@@ -143,7 +142,7 @@ import { Icon } from "astro-icon/components"; // Dispatch a custom event with the selected solution label, // so a React component can listen to it using `window.addEventListener`. window.dispatchEvent( - new CustomEvent("custom_event:solution", { + new CustomEvent("custom_event:react_form", { detail: button.dataset.label, }), ); diff --git a/superpage/src/components/Course/_bkp.astro b/superpage/src/components/Course/_bkp.astro deleted file mode 100644 index 308baa9..0000000 --- a/superpage/src/components/Course/_bkp.astro +++ /dev/null @@ -1,155 +0,0 @@ ---- -import { Icon } from "astro-icon/components"; -import Container from "../Container.astro"; - -import { getCollection } from "astro:content"; -const courses = await getCollection( - "courses", - ({ data }) => data.draft != true, -); - -const { title } = Astro.props; ---- - - diff --git a/superpage/src/pages/_components/BuyButton.astro b/superpage/src/pages/_components/BuyButton.astro index 32d324e..de78a06 100644 --- a/superpage/src/pages/_components/BuyButton.astro +++ b/superpage/src/pages/_components/BuyButton.astro @@ -69,6 +69,20 @@ const currency = new Intl.NumberFormat("pt-BR", { target.disabled = true; + window.dataLayer?.push({ + event: "add_to_cart", + currency: "BRL", + value: parseFloat(unit_price), + items: [ + { + item_id: id, + item_name: name, + price: parseFloat(unit_price), + quantity: 1, + }, + ], + }); + const r = await checkout(item); const json = await r.json();