feat: add contact form API integration and UI improvements

- Connect contact form to backend API endpoint
- Add email thetiptopgr3@gmail.com to contact and about pages
- Replace about page gradient with actual image
- Change Thé bio icon from emoji to Leaf component
- Remove dates from game period sections
- Add proper error handling for contact form

🤖 Generated with Claude Code

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
soufiane 2025-11-24 11:40:41 +01:00
parent 048db0b2a6
commit 152563b5e5
4 changed files with 383 additions and 95 deletions

View File

@ -2,7 +2,9 @@
import type { Metadata } from "next"; import type { Metadata } from "next";
import Link from "next/link"; import Link from "next/link";
import Image from "next/image";
import { useState } from "react"; import { useState } from "react";
import { Leaf } from "lucide-react";
export default function AboutPage() { export default function AboutPage() {
return ( return (
@ -45,21 +47,19 @@ export default function AboutPage() {
{/* Image */} {/* Image */}
<div className="order-1 md:order-2"> <div className="order-1 md:order-2">
<div className="relative rounded-2xl overflow-hidden shadow-2xl"> <div className="relative rounded-2xl overflow-hidden shadow-2xl h-full min-h-[500px]">
{/* Fallback avec illustration CSS si l'image n'existe pas */} <Image
<div className="aspect-[4/3] bg-gradient-to-br from-[#1a4d2e] via-[#2d5a3d] to-[#1a4d2e] relative"> src="/images/lots/about-img.jpg"
{/* Motif décoratif */} alt="Thé Tip Top Nice - Notre boutique de thé"
<div className="absolute inset-0 opacity-20"> fill
<div className="absolute inset-0" style={{ className="object-cover"
backgroundImage: 'url("data:image/svg+xml,%3Csvg width=\'60\' height=\'60\' viewBox=\'0 0 60 60\' xmlns=\'http://www.w3.org/2000/svg\'%3E%3Cg fill=\'none\' fill-rule=\'evenodd\'%3E%3Cg fill=\'%23ffffff\' fill-opacity=\'0.3\'%3E%3Cpath d=\'M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z\'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E")', priority
}}></div> />
</div>
</div> </div>
</div> </div>
</div> </div>
</div> </div>
</div> </div>
</div>
</section> </section>
{/* notre engagement Section */} {/* notre engagement Section */}
<section className="py-16 bg-white/50 backdrop-blur-sm"> <section className="py-16 bg-white/50 backdrop-blur-sm">
@ -71,7 +71,9 @@ export default function AboutPage() {
</div> </div>
<div className="grid md:grid-cols-3 gap-4"> <div className="grid md:grid-cols-3 gap-4">
<div className="bg-gradient-to-br from-[#d4a574]/10 to-[#c4956a]/10 rounded-lg p-6 text-center border border-[#d4a574]/20 hover:shadow-lg transition-shadow"> <div className="bg-gradient-to-br from-[#d4a574]/10 to-[#c4956a]/10 rounded-lg p-6 text-center border border-[#d4a574]/20 hover:shadow-lg transition-shadow">
<div className="w-16 h-16 mx-auto mb-4 bg-gradient-to-br from-[#d4a574] to-[#c4956a] rounded-full flex items-center justify-center text-3xl shadow-lg">🍵</div> <div className="w-16 h-16 mx-auto mb-4 bg-gradient-to-br from-[#d4a574] to-[#c4956a] rounded-full flex items-center justify-center shadow-lg">
<Leaf className="w-8 h-8 text-white" />
</div>
<div className="text-2xl font-bold text-[#5a5a4e] mb-2">Thé bio</div> <div className="text-2xl font-bold text-[#5a5a4e] mb-2">Thé bio</div>
<p className="text-sm text-[#8a8a7a]"> <p className="text-sm text-[#8a8a7a]">
Tous nos thés sont certifiés biologiques et cultivés dans le respect de l'environnement. Tous nos thés sont certifiés biologiques et cultivés dans le respect de l'environnement.
@ -108,6 +110,25 @@ export default function AboutPage() {
</div> </div>
</div> </div>
</section> </section>
{/* Contact Section */}
<section className="py-12 bg-gradient-to-br from-[#d4a574]/10 to-[#c4956a]/10">
<div className="container mx-auto px-4">
<div className="max-w-3xl mx-auto text-center">
<h3 className="text-2xl font-bold text-[#5a5a4e] mb-4">Contactez-nous</h3>
<p className="text-[#8a8a7a] mb-4">
Une question sur notre histoire ou nos thés ? N'hésitez pas à nous écrire !
</p>
<a
href="mailto:thetiptopgr3@gmail.com"
className="inline-flex items-center gap-2 text-[#d4a574] hover:text-[#c4956a] font-semibold transition-colors"
>
<span></span>
thetiptopgr3@gmail.com
</a>
</div>
</div>
</section>
</div> </div>
); );
} }

View File

@ -27,21 +27,43 @@ export default function ContactPage() {
e.preventDefault(); e.preventDefault();
setIsSubmitting(true); setIsSubmitting(true);
// Simulation d'envoi try {
await new Promise(resolve => setTimeout(resolve, 1500)); // Appel à l'API backend
const response = await fetch('http://localhost:4000/api/contact', {
method: 'POST',
headers: {
'Content-Type': 'application/json',
},
body: JSON.stringify({
fullName: formData.fullName,
email: formData.email,
subject: formData.subject,
message: formData.message,
}),
});
console.log('Form submitted:', formData); const data = await response.json();
alert('Votre message a été envoyé avec succès !');
// Reset form if (response.ok && data.success) {
setFormData({ alert('✅ Votre message a été envoyé avec succès ! Nous vous répondrons dans les plus brefs délais.');
fullName: '',
email: '', // Reset form
subject: '', setFormData({
message: '', fullName: '',
acceptPolicy: false, email: '',
}); subject: '',
setIsSubmitting(false); message: '',
acceptPolicy: false,
});
} else {
alert('❌ ' + (data.message || 'Une erreur est survenue. Veuillez réessayer.'));
}
} catch (error) {
console.error('Erreur lors de l\'envoi du message:', error);
alert('❌ Une erreur est survenue lors de l\'envoi de votre message. Veuillez réessayer.');
} finally {
setIsSubmitting(false);
}
}; };
return ( return (
@ -221,18 +243,8 @@ export default function ContactPage() {
<h3 className="font-semibold text-[#5a5a4e] mb-1">Email</h3> <h3 className="font-semibold text-[#5a5a4e] mb-1">Email</h3>
<div className="text-[#8a8a7a] text-sm space-y-1"> <div className="text-[#8a8a7a] text-sm space-y-1">
<p> <p>
<a href="mailto:contact@thetiptop.com" className="hover:text-[#d4a574] transition-colors"> <a href="mailto:thetiptopgr3@gmail.com" className="hover:text-[#d4a574] transition-colors">
contact@thetiptop.com thetiptopgr3@gmail.com
</a>
</p>
<p>
<a href="mailto:support@thetiptop.com" className="hover:text-[#d4a574] transition-colors">
support@thetiptop.com
</a>
</p>
<p>
<a href="mailto:privacy@thetiptop.com" className="hover:text-[#d4a574] transition-colors">
privacy@thetiptop.com
</a> </a>
</p> </p>
</div> </div>

311
app/page.tsx.backup Normal file
View File

@ -0,0 +1,311 @@
'use client';
import Link from "next/link";
import Image from "next/image";
import Button from "@/components/Button";
import CountdownTimer from "@/components/CountdownTimer";
import GamePeriod from "@/components/GamePeriod";
import GrandPrize from "@/components/GrandPrize";
import AboutContest from "@/components/AboutContest";
import { useState } from "react";
export default function HomePage() {
const [animationKey] = useState(Date.now());
return (
<div className="min-h-screen -mt-[4.5rem] relative">
{/* Background avec icônes de thé */}
<div className="fixed inset-0 -z-10 overflow-hidden">
{/* Fond dégradé beige clair */}
<div className="absolute inset-0 bg-gradient-to-br from-[#fdfcf8] via-[#f8f6f0] to-[#f0ede5]"></div>
{/* Icônes de thé dispersées avec animation de descente - 35 icônes */}
<div key={animationKey} className="absolute inset-0 opacity-[0.5]">
{/* Ligne 1 - 5 icons */}
<Image src="/images/tea-icons/teapot-green.png" alt="" width={56} height={56} className="absolute top-[5%] left-[10%] animate-float-gentle" style={{animationDuration: '28s'}} />
<Image src="/images/tea-icons/tea-cup.png" alt="" width={56} height={56} className="absolute top-[7%] left-[30%] animate-float-gentle" style={{animationDuration: '32s'}} />
<Image src="/images/tea-icons/gift-box.png" alt="" width={56} height={56} className="absolute top-[6%] left-[50%] animate-float-gentle" style={{animationDuration: '30s'}} />
<Image src="/images/tea-icons/tea-leaves.png" alt="" width={56} height={56} className="absolute top-[8%] left-[70%] animate-float-gentle" style={{animationDuration: '27s'}} />
<Image src="/images/tea-icons/teapot-pink.png" alt="" width={56} height={56} className="absolute top-[5%] left-[90%] animate-float-gentle" style={{animationDuration: '31s'}} />
{/* Ligne 2 - 5 icons */}
<Image src="/images/tea-icons/tea-leaves.png" alt="" width={56} height={56} className="absolute top-[18%] left-[15%] animate-float-gentle" style={{animationDuration: '29s'}} />
<Image src="/images/tea-icons/teapot-green.png" alt="" width={56} height={56} className="absolute top-[20%] left-[35%] animate-float-gentle" style={{animationDuration: '26s'}} />
<Image src="/images/tea-icons/tea-cup.png" alt="" width={56} height={56} className="absolute top-[19%] left-[55%] animate-float-gentle" style={{animationDuration: '33s'}} />
<Image src="/images/tea-icons/gift-box.png" alt="" width={56} height={56} className="absolute top-[21%] left-[75%] animate-float-gentle" style={{animationDuration: '28s'}} />
<Image src="/images/tea-icons/teapot-pink.png" alt="" width={56} height={56} className="absolute top-[18%] left-[95%] animate-float-gentle" style={{animationDuration: '30s'}} />
{/* Ligne 3 - 5 icons */}
<Image src="/images/tea-icons/gift-box.png" alt="" width={56} height={56} className="absolute top-[31%] left-[10%] animate-float-gentle" style={{animationDuration: '27s'}} />
<Image src="/images/tea-icons/tea-cup.png" alt="" width={56} height={56} className="absolute top-[33%] left-[30%] animate-float-gentle" style={{animationDuration: '31s'}} />
<Image src="/images/tea-icons/teapot-green.png" alt="" width={56} height={56} className="absolute top-[32%] left-[50%] animate-float-gentle" style={{animationDuration: '29s'}} />
<Image src="/images/tea-icons/tea-leaves.png" alt="" width={56} height={56} className="absolute top-[34%] left-[70%] animate-float-gentle" style={{animationDuration: '26s'}} />
<Image src="/images/tea-icons/teapot-pink.png" alt="" width={56} height={56} className="absolute top-[31%] left-[90%] animate-float-gentle" style={{animationDuration: '32s'}} />
{/* Ligne 4 - 5 icons */}
<Image src="/images/tea-icons/tea-leaves.png" alt="" width={56} height={56} className="absolute top-[44%] left-[15%] animate-float-gentle" style={{animationDuration: '28s'}} />
<Image src="/images/tea-icons/teapot-pink.png" alt="" width={56} height={56} className="absolute top-[46%] left-[35%] animate-float-gentle" style={{animationDuration: '30s'}} />
<Image src="/images/tea-icons/gift-box.png" alt="" width={56} height={56} className="absolute top-[45%] left-[55%] animate-float-gentle" style={{animationDuration: '33s'}} />
<Image src="/images/tea-icons/teapot-green.png" alt="" width={56} height={56} className="absolute top-[47%] left-[75%] animate-float-gentle" style={{animationDuration: '27s'}} />
<Image src="/images/tea-icons/tea-cup.png" alt="" width={56} height={56} className="absolute top-[44%] left-[95%] animate-float-gentle" style={{animationDuration: '29s'}} />
{/* Ligne 5 - 5 icons */}
<Image src="/images/tea-icons/teapot-green.png" alt="" width={56} height={56} className="absolute top-[57%] left-[10%] animate-float-gentle" style={{animationDuration: '31s'}} />
<Image src="/images/tea-icons/tea-leaves.png" alt="" width={56} height={56} className="absolute top-[59%] left-[30%] animate-float-gentle" style={{animationDuration: '26s'}} />
<Image src="/images/tea-icons/tea-cup.png" alt="" width={56} height={56} className="absolute top-[58%] left-[50%] animate-float-gentle" style={{animationDuration: '30s'}} />
<Image src="/images/tea-icons/gift-box.png" alt="" width={56} height={56} className="absolute top-[60%] left-[70%] animate-float-gentle" style={{animationDuration: '28s'}} />
<Image src="/images/tea-icons/teapot-pink.png" alt="" width={56} height={56} className="absolute top-[57%] left-[90%] animate-float-gentle" style={{animationDuration: '32s'}} />
{/* Ligne 6 - 5 icons */}
<Image src="/images/tea-icons/tea-cup.png" alt="" width={56} height={56} className="absolute top-[70%] left-[15%] animate-float-gentle" style={{animationDuration: '29s'}} />
<Image src="/images/tea-icons/gift-box.png" alt="" width={56} height={56} className="absolute top-[72%] left-[35%] animate-float-gentle" style={{animationDuration: '27s'}} />
<Image src="/images/tea-icons/teapot-pink.png" alt="" width={56} height={56} className="absolute top-[71%] left-[55%] animate-float-gentle" style={{animationDuration: '31s'}} />
<Image src="/images/tea-icons/tea-leaves.png" alt="" width={56} height={56} className="absolute top-[73%] left-[75%] animate-float-gentle" style={{animationDuration: '28s'}} />
<Image src="/images/tea-icons/teapot-green.png" alt="" width={56} height={56} className="absolute top-[70%] left-[95%] animate-float-gentle" style={{animationDuration: '30s'}} />
{/* Ligne 7 - 5 icons */}
<Image src="/images/tea-icons/gift-box.png" alt="" width={56} height={56} className="absolute top-[83%] left-[10%] animate-float-gentle" style={{animationDuration: '26s'}} />
<Image src="/images/tea-icons/teapot-green.png" alt="" width={56} height={56} className="absolute top-[85%] left-[30%] animate-float-gentle" style={{animationDuration: '32s'}} />
<Image src="/images/tea-icons/tea-leaves.png" alt="" width={56} height={56} className="absolute top-[84%] left-[50%] animate-float-gentle" style={{animationDuration: '29s'}} />
<Image src="/images/tea-icons/tea-cup.png" alt="" width={56} height={56} className="absolute top-[86%] left-[70%] animate-float-gentle" style={{animationDuration: '27s'}} />
<Image src="/images/tea-icons/teapot-pink.png" alt="" width={56} height={56} className="absolute top-[83%] left-[90%] animate-float-gentle" style={{animationDuration: '31s'}} />
</div>
{/* Overlay lumineux pour harmoniser */}
<div className="absolute inset-0 bg-gradient-radial from-white/30 via-transparent to-transparent"></div>
</div>
{/* Hero Section - Bannière principale */}
<section className="relative min-h-[600px] pt-32 pb-24 overflow-hidden">
<div className="w-full relative z-10">
<div className="w-full text-center px-4">
<h1 className="text-5xl md:text-7xl font-bold text-[#5a5a4e] mb-6 leading-tight drop-shadow-sm">
Jeu Concours Thé Tip Top<br />
<span className="text-[#d4a574]">Nice</span>
</h1>
<p className="text-xl md:text-2xl text-[#6a6a5e] mb-8 leading-relaxed max-w-4xl mx-auto">
À l'occasion de l'ouverture de notre 10<sup>ème</sup> boutique de thé premium à Nice,<br />
participez à notre concours et gagnez des thés et accessoires exclusifs !
</p>
<div className="flex flex-col sm:flex-row gap-4 justify-center px-4">
<Link href="/register">
<button className="bg-[#d4a574] hover:bg-[#c4956a] text-white font-bold text-lg px-12 py-5 rounded-full shadow-2xl transition-all w-full sm:w-auto hover:scale-105">
Jouer maintenant
</button>
</Link>
</div>
</div>
</div>
</section>
{/* Game Period & Countdown Section */}
<section className="py-20 bg-transparent">
<div className="container mx-auto px-4">
<div className="max-w-6xl mx-auto">
{/* Countdown Timer */}
<CountdownTimer
endDate={new Date('2025-12-31T23:59:59')}
title="Fin du concours dans"
/>
{/* Game Period Cards */}
<GamePeriod
purchaseStartDate={new Date('2025-01-01')}
purchaseEndDate={new Date('2025-12-31')}
gameStartDate={new Date('2025-01-01')}
gameEndDate={new Date('2025-12-31')}
/>
{/* Grand Prize Banner */}
<GrandPrize
prizeAmount="360€"
drawDate={new Date('2026-01-15')}
participantsCount={15420}
/>
</div>
</div>
</section>
{/* About Contest Section */}
<AboutContest />
{/* How to Participate Section */}
<section className="py-20 bg-white/60 backdrop-blur-sm">
<div className="container mx-auto px-4">
<div className="max-w-5xl mx-auto">
<h2 className="text-4xl md:text-5xl font-bold text-center text-gray-900 mb-4">
Comment participer?
</h2>
<p className="text-center text-gray-600 mb-16 text-lg max-w-2xl mx-auto">
3 étapes simples pour découvrir votre lot et rejoindre nos milliers de gagnants
</p>
<div className="grid md:grid-cols-3 gap-12">
{/* Step 1 */}
<div className="text-center relative">
<div className="absolute top-0 right-0 w-8 h-8 bg-[#1a4d2e] text-white rounded-full flex items-center justify-center font-bold text-sm">
1
</div>
<div className="bg-gradient-to-br from-[#fef3c7] to-[#fde68a] w-20 h-20 rounded-full flex items-center justify-center mx-auto mb-6 shadow-lg">
<svg className="w-10 h-10 text-[#1a4d2e]" fill="none" stroke="currentColor" viewBox="0 0 24 24">
<path strokeLinecap="round" strokeLinejoin="round" strokeWidth={2} d="M16 7a4 4 0 11-8 0 4 4 0 018 0zM12 14a7 7 0 00-7 7h14a7 7 0 00-7-7z" />
</svg>
</div>
<h3 className="text-2xl font-bold mb-3 text-gray-900">Inscrivez-vous</h3>
<p className="text-gray-600 leading-relaxed">
Créez votre compte rapidement avec Google, Facebook ou votre email
</p>
</div>
{/* Step 2 */}
<div className="text-center relative">
<div className="absolute top-0 right-0 w-8 h-8 bg-[#1a4d2e] text-white rounded-full flex items-center justify-center font-bold text-sm">
2
</div>
<div className="bg-gradient-to-br from-[#fef3c7] to-[#fde68a] w-20 h-20 rounded-full flex items-center justify-center mx-auto mb-6 shadow-lg">
<svg className="w-10 h-10 text-[#1a4d2e]" fill="none" stroke="currentColor" viewBox="0 0 24 24">
<path strokeLinecap="round" strokeLinejoin="round" strokeWidth={2} d="M15 5v2m0 4v2m0 4v2M5 5a2 2 0 00-2 2v3a2 2 0 110 4v3a2 2 0 002 2h14a2 2 0 002-2v-3a2 2 0 110-4V7a2 2 0 00-2-2H5z" />
</svg>
</div>
<h3 className="text-2xl font-bold mb-3 text-gray-900">Entrez votre code</h3>
<p className="text-gray-600 leading-relaxed">
Saisissez le code à 10 caractères de votre ticket d'achat à 49€
</p>
</div>
{/* Step 3 */}
<div className="text-center relative">
<div className="absolute top-0 right-0 w-8 h-8 bg-[#1a4d2e] text-white rounded-full flex items-center justify-center font-bold text-sm">
3
</div>
<div className="bg-gradient-to-br from-[#fef3c7] to-[#fde68a] w-20 h-20 rounded-full flex items-center justify-center mx-auto mb-6 shadow-lg">
<svg className="w-10 h-10 text-[#1a4d2e]" fill="none" stroke="currentColor" viewBox="0 0 24 24">
<path strokeLinecap="round" strokeLinejoin="round" strokeWidth={2} d="M12 8v13m0-13V6a2 2 0 112 2h-2zm0 0V5.5A2.5 2.5 0 109.5 8H12zm-7 4h14M5 12a2 2 0 110-4h14a2 2 0 110 4M5 12v7a2 2 0 002 2h10a2 2 0 002-2v-7" />
</svg>
</div>
<h3 className="text-2xl font-bold mb-3 text-gray-900">Découvrez votre lot</h3>
<p className="text-gray-600 leading-relaxed">
Résultat immédiat ! 100% des participants remportent un prix
</p>
</div>
</div>
</div>
</div>
</section>
{/* Prizes Section */}
<section className="py-20 bg-transparent">
<div className="container mx-auto px-4">
<div className="max-w-6xl mx-auto">
<h2 className="text-4xl md:text-5xl font-bold text-center text-gray-900 mb-4">
Lots à gagner
</h2>
<p className="text-center text-gray-600 mb-16 text-lg max-w-3xl mx-auto">
Découvrez nos magnifiques prix, des accessoires premium aux coffrets exclusifs
</p>
<div className="grid md:grid-cols-2 lg:grid-cols-5 gap-6">
{/* Prize 1 */}
<div className="bg-white rounded-xl shadow-lg overflow-hidden hover:shadow-2xl transition-shadow border border-gray-100">
<div className="aspect-square bg-gradient-to-br from-amber-50 to-orange-50 flex items-center justify-center p-8">
<div className="text-7xl">🍵</div>
</div>
<div className="p-6">
<div className="inline-block bg-red-100 text-red-600 text-sm font-bold px-3 py-1 rounded-full mb-3">
60%
</div>
<h3 className="text-xl font-bold text-gray-900 mb-2">Infuseur à thé premium</h3>
<p className="text-gray-600 text-sm">
Un infuseur élégant pour vos thés en vrac
</p>
</div>
</div>
{/* Prize 2 */}
<div className="bg-white rounded-xl shadow-lg overflow-hidden hover:shadow-2xl transition-shadow border border-gray-100">
<div className="aspect-square bg-gradient-to-br from-green-50 to-emerald-50 flex items-center justify-center p-8">
<div className="text-7xl">📦</div>
</div>
<div className="p-6">
<div className="inline-block bg-orange-100 text-orange-600 text-sm font-bold px-3 py-1 rounded-full mb-3">
20%
</div>
<h3 className="text-xl font-bold text-gray-900 mb-2">Boîte 100g thé détox</h3>
<p className="text-gray-600 text-sm">
Mélange détox aux plantes bio
</p>
</div>
</div>
{/* Prize 3 */}
<div className="bg-white rounded-xl shadow-lg overflow-hidden hover:shadow-2xl transition-shadow border border-gray-100">
<div className="aspect-square bg-gradient-to-br from-blue-50 to-cyan-50 flex items-center justify-center p-8">
<div className="text-7xl">🌿</div>
</div>
<div className="p-6">
<div className="inline-block bg-green-100 text-green-600 text-sm font-bold px-3 py-1 rounded-full mb-3">
10%
</div>
<h3 className="text-xl font-bold text-gray-900 mb-2">Boîte 100g thé signature</h3>
<p className="text-gray-600 text-sm">
Notre mélange signature exclusif
</p>
</div>
</div>
{/* Prize 4 */}
<div className="bg-white rounded-xl shadow-lg overflow-hidden hover:shadow-2xl transition-shadow border border-gray-100">
<div className="aspect-square bg-gradient-to-br from-purple-50 to-pink-50 flex items-center justify-center p-8">
<div className="text-7xl">🎁</div>
</div>
<div className="p-6">
<div className="inline-block bg-purple-100 text-purple-600 text-sm font-bold px-3 py-1 rounded-full mb-3">
6%
</div>
<h3 className="text-xl font-bold text-gray-900 mb-2">Coffret découverte 39€</h3>
<p className="text-gray-600 text-sm">
Sélection de nos meilleurs thés
</p>
</div>
</div>
{/* Prize 5 */}
<div className="bg-white rounded-xl shadow-lg overflow-hidden hover:shadow-2xl transition-shadow border-2 border-[#f59e0b]">
<div className="aspect-square bg-gradient-to-br from-yellow-50 to-amber-50 flex items-center justify-center p-8">
<div className="text-7xl">🏆</div>
</div>
<div className="p-6">
<div className="inline-block bg-yellow-100 text-yellow-700 text-sm font-bold px-3 py-1 rounded-full mb-3">
4%
</div>
<h3 className="text-xl font-bold text-gray-900 mb-2">Coffret découverte 69€</h3>
<p className="text-gray-600 text-sm">
Une expérience complète
</p>
</div>
</div>
</div>
<div className="text-center mt-12">
<Link href="/lots">
<Button
variant="outline"
size="lg"
className="border-2 border-[#1a4d2e] text-[#1a4d2e] hover:bg-[#1a4d2e] hover:text-white font-semibold px-8"
>
Voir tous les lots
<svg className="w-5 h-5 ml-2" fill="none" stroke="currentColor" viewBox="0 0 24 24">
<path strokeLinecap="round" strokeLinejoin="round" strokeWidth={2} d="M9 5l7 7-7 7" />
</svg>
</Button>
</Link>
</div>
</div>
</div>
</section>
</div>
);
}

View File

@ -1,26 +1,6 @@
'use client'; 'use client';
interface GamePeriodProps { export default function GamePeriod() {
purchaseStartDate: Date;
purchaseEndDate: Date;
gameStartDate: Date;
gameEndDate: Date;
}
export default function GamePeriod({
purchaseStartDate,
purchaseEndDate,
gameStartDate,
gameEndDate,
}: GamePeriodProps) {
const formatDate = (date: Date) => {
return date.toLocaleDateString('fr-FR', {
day: 'numeric',
month: 'long',
year: 'numeric',
});
};
return ( return (
<div className="grid md:grid-cols-2 gap-6 mt-8"> <div className="grid md:grid-cols-2 gap-6 mt-8">
{/* Période d'achat */} {/* Période d'achat */}
@ -33,27 +13,9 @@ export default function GamePeriod({
</div> </div>
<div className="flex-1"> <div className="flex-1">
<h3 className="text-2xl font-bold text-gray-900 mb-3">Période d'achat</h3> <h3 className="text-2xl font-bold text-gray-900 mb-3">Période d'achat</h3>
<p className="text-gray-600 mb-4"> <p className="text-gray-600">
Achetez vos tickets de 49 en boutique et obtenez votre code de participation Achetez vos tickets de 49 en boutique et obtenez votre code de participation
</p> </p>
<div className="space-y-2">
<div className="flex items-center gap-2 text-sm">
<svg className="w-5 h-5 text-green-600" fill="currentColor" viewBox="0 0 20 20">
<path fillRule="evenodd" d="M10 18a8 8 0 100-16 8 8 0 000 16zm1-12a1 1 0 10-2 0v4a1 1 0 00.293.707l2.828 2.829a1 1 0 101.415-1.415L11 9.586V6z" clipRule="evenodd" />
</svg>
<span className="text-gray-700">
<span className="font-semibold">Du</span> {formatDate(purchaseStartDate)}
</span>
</div>
<div className="flex items-center gap-2 text-sm">
<svg className="w-5 h-5 text-red-600" fill="currentColor" viewBox="0 0 20 20">
<path fillRule="evenodd" d="M10 18a8 8 0 100-16 8 8 0 000 16zm1-12a1 1 0 10-2 0v4a1 1 0 00.293.707l2.828 2.829a1 1 0 101.415-1.415L11 9.586V6z" clipRule="evenodd" />
</svg>
<span className="text-gray-700">
<span className="font-semibold">Au</span> {formatDate(purchaseEndDate)}
</span>
</div>
</div>
</div> </div>
</div> </div>
</div> </div>
@ -68,27 +30,9 @@ export default function GamePeriod({
</div> </div>
<div className="flex-1"> <div className="flex-1">
<h3 className="text-2xl font-bold text-gray-900 mb-3">Période de jeu</h3> <h3 className="text-2xl font-bold text-gray-900 mb-3">Période de jeu</h3>
<p className="text-gray-600 mb-4"> <p className="text-gray-600">
Utilisez vos tickets pour jouer et découvrir vos lots instantanément Utilisez vos tickets pour jouer et découvrir vos lots instantanément
</p> </p>
<div className="space-y-2">
<div className="flex items-center gap-2 text-sm">
<svg className="w-5 h-5 text-green-600" fill="currentColor" viewBox="0 0 20 20">
<path fillRule="evenodd" d="M10 18a8 8 0 100-16 8 8 0 000 16zm1-12a1 1 0 10-2 0v4a1 1 0 00.293.707l2.828 2.829a1 1 0 101.415-1.415L11 9.586V6z" clipRule="evenodd" />
</svg>
<span className="text-gray-700">
<span className="font-semibold">Du</span> {formatDate(gameStartDate)}
</span>
</div>
<div className="flex items-center gap-2 text-sm">
<svg className="w-5 h-5 text-red-600" fill="currentColor" viewBox="0 0 20 20">
<path fillRule="evenodd" d="M10 18a8 8 0 100-16 8 8 0 000 16zm1-12a1 1 0 10-2 0v4a1 1 0 00.293.707l2.828 2.829a1 1 0 101.415-1.415L11 9.586V6z" clipRule="evenodd" />
</svg>
<span className="text-gray-700">
<span className="font-semibold">Au</span> {formatDate(gameEndDate)}
</span>
</div>
</div>
</div> </div>
</div> </div>
</div> </div>