Merge version_7 into main #8
@@ -1,45 +1,55 @@
|
||||
"use client";
|
||||
|
||||
import { ThemeProvider } from "@/providers/themeProvider/ThemeProvider";
|
||||
import ReactLenis from "lenis/react";
|
||||
import NavbarStyleFullscreen from '@/components/navbar/NavbarStyleFullscreen/NavbarStyleFullscreen';
|
||||
import CardStack from '@/components/cardStack/CardStack';
|
||||
import { useState } from 'react';
|
||||
|
||||
export default function ChatPage() {
|
||||
const [grokApiKey] = useState("");
|
||||
|
||||
return (
|
||||
<ThemeProvider
|
||||
defaultButtonVariant="text-stagger"
|
||||
defaultTextAnimation="entrance-slide"
|
||||
borderRadius="rounded"
|
||||
contentWidth="medium"
|
||||
sizing="medium"
|
||||
background="circleGradient"
|
||||
cardStyle="glass-elevated"
|
||||
primaryButtonStyle="gradient"
|
||||
secondaryButtonStyle="glass"
|
||||
headingFontWeight="normal"
|
||||
<ThemeProvider
|
||||
defaultButtonVariant="icon-arrow"
|
||||
defaultTextAnimation="background-highlight"
|
||||
borderRadius="soft"
|
||||
contentWidth="medium"
|
||||
sizing="mediumLargeSizeMediumTitles"
|
||||
background="noise"
|
||||
cardStyle="outline"
|
||||
primaryButtonStyle="flat"
|
||||
secondaryButtonStyle="solid"
|
||||
headingFontWeight="semibold"
|
||||
>
|
||||
<div id="nav" data-section="nav">
|
||||
<ReactLenis root>
|
||||
<NavbarStyleFullscreen
|
||||
navItems={[
|
||||
{ name: "Accueil", id: "/" },
|
||||
{ name: "Chat", id: "/chat" },
|
||||
]}
|
||||
brandName="MathIA Chat"
|
||||
navItems={[
|
||||
{ name: "Accueil", id: "/" },
|
||||
{ name: "Chat", id: "/chat" },
|
||||
{ name: "Fonctionnalités", id: "/#features" },
|
||||
{ name: "FAQ", id: "/#faq" },
|
||||
{ name: "Contact", id: "/#contact" },
|
||||
]}
|
||||
brandName="MathIA Grok"
|
||||
/>
|
||||
</div>
|
||||
<main className="container mx-auto p-8 pt-32 min-h-screen flex flex-col md:flex-row gap-8">
|
||||
<div className="flex-1 border border-neutral-800 rounded-xl p-6 bg-neutral-900">
|
||||
<h2 className="text-2xl font-bold mb-4">Tuteur Grok</h2>
|
||||
<div className="h-96 w-full flex items-center justify-center border border-neutral-700 rounded bg-black/50">
|
||||
<p className="text-neutral-500">[Tuteur IA xAI activé]</p>
|
||||
</div>
|
||||
<div className="min-h-screen pt-24 pb-12">
|
||||
<CardStack
|
||||
title="Grok Chat Interface"
|
||||
description={grokApiKey ? "Connecté au moteur xAI - Tuteur mathématique activé." : "Veuillez configurer votre clé API xAI dans la section contact pour activer le tuteur IA."}
|
||||
textboxLayout="split"
|
||||
animationType="blur-reveal"
|
||||
ariaLabel="Chat interface"
|
||||
className="bg-black text-white"
|
||||
>
|
||||
<div className="flex flex-col gap-4 p-8 border border-neutral-800 rounded-lg">
|
||||
<div className="text-sm text-neutral-400">{grokApiKey ? "xAI/Grok: Système en ligne. Quelle équation souhaitez-vous résoudre ?" : "xAI/Grok: En attente de configuration API..."}</div>
|
||||
<div className="h-px w-full bg-neutral-800 my-2" />
|
||||
<div className="text-white font-medium">User: Explique-moi le calcul intégral.</div>
|
||||
</div>
|
||||
</CardStack>
|
||||
</div>
|
||||
<div className="flex-[2] border border-neutral-800 rounded-xl p-6 bg-white">
|
||||
<h2 className="text-2xl font-bold mb-4 text-black">Whiteboard</h2>
|
||||
<div className="h-96 w-full border border-neutral-300 rounded bg-white shadow-inner">
|
||||
<p className="p-4 text-neutral-400">[Espace de calcul visuel]</p>
|
||||
</div>
|
||||
</div>
|
||||
</main>
|
||||
</ReactLenis>
|
||||
</ThemeProvider>
|
||||
);
|
||||
}
|
||||
|
||||
@@ -10,20 +10,9 @@ import HeroLogoBillboardSplit from '@/components/sections/hero/HeroLogoBillboard
|
||||
import MediaAbout from '@/components/sections/about/MediaAbout';
|
||||
import NavbarStyleFullscreen from '@/components/navbar/NavbarStyleFullscreen/NavbarStyleFullscreen';
|
||||
import { Lightbulb, Monitor, PenTool, ShieldCheck, Zap } from "lucide-react";
|
||||
import CardStack from '@/components/cardStack/CardStack';
|
||||
import { useState } from 'react';
|
||||
|
||||
export default function LandingPage() {
|
||||
const [grokApiKey, setGrokApiKey] = useState("");
|
||||
|
||||
const handleContactSubmit = (data: Record<string, string>) => {
|
||||
if (data.apiKey) {
|
||||
// Store API key in memory for chat/tutor functionality
|
||||
setGrokApiKey(data.apiKey);
|
||||
console.log("xAI/Grok API Key integrated successfully");
|
||||
}
|
||||
};
|
||||
|
||||
return (
|
||||
<ThemeProvider
|
||||
defaultButtonVariant="icon-arrow"
|
||||
@@ -42,7 +31,7 @@ export default function LandingPage() {
|
||||
<NavbarStyleFullscreen
|
||||
navItems={[
|
||||
{ name: "Accueil", id: "hero" },
|
||||
{ name: "Chat", id: "chat" },
|
||||
{ name: "Chat", id: "/chat" },
|
||||
{ name: "Fonctionnalités", id: "features" },
|
||||
{ name: "FAQ", id: "faq" },
|
||||
{ name: "Contact", id: "contact" },
|
||||
@@ -66,23 +55,6 @@ export default function LandingPage() {
|
||||
/>
|
||||
</div>
|
||||
|
||||
<div id="chat" data-section="chat">
|
||||
<CardStack
|
||||
title="Grok Chat Interface"
|
||||
description={grokApiKey ? "Connecté au moteur xAI - Tuteur mathématique activé." : "Veuillez configurer votre clé API xAI dans la section contact pour activer le tuteur IA."}
|
||||
textboxLayout="split"
|
||||
animationType="blur-reveal"
|
||||
ariaLabel="Chat interface"
|
||||
className="bg-black text-white"
|
||||
>
|
||||
<div className="flex flex-col gap-4 p-8 border border-neutral-800 rounded-lg">
|
||||
<div className="text-sm text-neutral-400">{grokApiKey ? "xAI/Grok: Système en ligne. Quelle équation souhaitez-vous résoudre ?" : "xAI/Grok: En attente de configuration API..."}</div>
|
||||
<div className="h-px w-full bg-neutral-800 my-2" />
|
||||
<div className="text-white font-medium">User: Explique-moi le calcul intégral.</div>
|
||||
</div>
|
||||
</CardStack>
|
||||
</div>
|
||||
|
||||
<div id="about" data-section="about">
|
||||
<MediaAbout
|
||||
useInvertedBackground={false}
|
||||
@@ -136,7 +108,6 @@ export default function LandingPage() {
|
||||
{ name: "email", type: "email", placeholder: "Email", required: true },
|
||||
{ name: "apiKey", type: "password", placeholder: "Clé API xAI", required: true },
|
||||
]}
|
||||
onSubmit={handleContactSubmit}
|
||||
imageSrc="https://webuild-dev.s3.eu-north-1.amazonaws.com/users/user_3BiavO3dCn02likxwS7upWoCIlU/futuristic-digital-aesthetic-background--1775133773550-69c25a60.png"
|
||||
mediaAnimation="blur-reveal"
|
||||
/>
|
||||
|
||||
Reference in New Issue
Block a user