From 39a1361666786c0a51da923038318adfa6e75ab8 Mon Sep 17 00:00:00 2001
From: Pierre-Gilles Leymarie
Date: Wed, 4 Dec 2024 08:22:53 +0100
Subject: [PATCH] Remove Black Friday offer (#282)
---
docusaurus.config.js | 6 ++--
src/components/Home.js | 2 +-
src/pages/starter-kit.js | 70 ++++++++++++++--------------------------
3 files changed, 28 insertions(+), 50 deletions(-)
diff --git a/docusaurus.config.js b/docusaurus.config.js
index 1b40a0d1..32316314 100644
--- a/docusaurus.config.js
+++ b/docusaurus.config.js
@@ -29,14 +29,14 @@ module.exports = {
defaultMode: "dark",
respectPrefersColorScheme: false,
},
- announcementBar: {
+ /* announcementBar: {
id: "black_friday_2024",
content:
'Black Friday: Promo extrême sur le kit de démarrage officiel !!',
backgroundColor: "#ff5722",
textColor: "white",
isCloseable: true,
- },
+ }, */
navbar: {
title: "Gladys Assistant",
logo: {
@@ -71,7 +71,7 @@ module.exports = {
position: "left",
},
{
- href: "https://formation.gladysassistant.com/?coupon=BLACKFRIDAYCRAZY",
+ href: "https://formation.gladysassistant.com/?coupon=HOMEPAGE_SALE_2024",
activeBasePath: "formation",
label: "Formation",
position: "left",
diff --git a/src/components/Home.js b/src/components/Home.js
index bba0db10..424fb416 100644
--- a/src/components/Home.js
+++ b/src/components/Home.js
@@ -313,7 +313,7 @@ function Home({ integrations, lang }) {
)}
href="/fr/starter-kit/"
>
- Black Friday: Promo sur le kit de démarrage !
+ Le kit de démarrage officiel
)}
diff --git a/src/pages/starter-kit.js b/src/pages/starter-kit.js
index e556ba54..9fdd61fa 100644
--- a/src/pages/starter-kit.js
+++ b/src/pages/starter-kit.js
@@ -127,33 +127,7 @@ function Plus() {
const [timeLeft, setTimeLeft] = useState(null);
- // Calculate the remaining time
useEffect(() => {
- const interval = setInterval(() => {
- const now = new Date().getTime();
- const distance = targetDate - now;
-
- if (distance <= 0) {
- clearInterval(interval); // Stop the countdown when the target date is reached
- } else {
- const days = Math.floor(distance / (1000 * 60 * 60 * 24));
- const hours = Math.floor(
- (distance % (1000 * 60 * 60 * 24)) / (1000 * 60 * 60)
- );
- const minutes = Math.floor((distance % (1000 * 60 * 60)) / (1000 * 60));
- const seconds = Math.floor((distance % (1000 * 60)) / 1000);
- if (days <= 1) {
- setTimeLeft({ days, hours, minutes, seconds });
- }
- }
- }, 1000);
-
- // Clean up the interval when component unmounts
- return () => clearInterval(interval);
- }, [targetDate]);
-
- useEffect(() => {
- console.log("useEffect");
fetchData();
}, []);
@@ -232,9 +206,11 @@ function Plus() {
(Retour sous 1 mois si insatisfait)
-
- Offre limitée Black Friday !
-
+ {false && (
+
+ Offre limitée Black Friday !
+
+ )}
-
-
-
- 🚨 {kitsRemaining} kits restants à ce prix
-
-
+
+
+ 🚨 {kitsRemaining} kits restants à ce prix
+
+
+ )}
{timeLeft && (
Temps restant:{" "}