+
{new Date(rev.created_at).toLocaleDateString('fr-FR', { day: 'numeric', month: 'long', year: 'numeric' })}
-
•
+
•
Quizz {rev.current_series}/{rev.total_series}
@@ -145,11 +145,11 @@ export const HistoryPage: React.FC = () => {
{rev.status === 'COMPLETED' && (
-
+
✅ Terminé
)}
-
@@ -158,11 +158,11 @@ export const HistoryPage: React.FC = () => {
})}
) : (
-
+
🔍
-
Aucun cours trouvé
-
Essaie une autre recherche ou crée un nouveau cours !
-
+
Aucun cours trouvé
+
Essaie une autre recherche ou crée un nouveau cours !
+
Créer un cours
diff --git a/frontend/src/features/quiz/QuestionCard.tsx b/frontend/src/features/quiz/QuestionCard.tsx
index ef49940..117079f 100644
--- a/frontend/src/features/quiz/QuestionCard.tsx
+++ b/frontend/src/features/quiz/QuestionCard.tsx
@@ -42,14 +42,14 @@ export function QuestionCard({
const isCorrect = selectedOption === correctAnswer;
return (
-
Question {currentStep} / {totalSteps}
- {Math.round((currentStep / totalSteps) * 100)}%
+ {Math.round((currentStep / totalSteps) * 100)}%
-
+
-
{question}
+
{question}
{options.map((option, index) => (
@@ -66,46 +66,46 @@ export function QuestionCard({
disabled={selectedOption !== null}
onClick={() => onSelectOption(index)}
className={`w-full text-left p-5 border-2 rounded-xl transition-all duration-200 group relative ${selectedOption === null
- ? 'border-slate-100 hover:border-soft-indigo hover:bg-indigo-50/30'
+ ? 'border-slate-100 dark:border-slate-700 hover:border-soft-indigo dark:hover:border-indigo-500 hover:bg-indigo-50/30 dark:hover:bg-indigo-900/20'
: selectedOption === index
? index === correctAnswer
- ? 'border-green-500 bg-green-50 text-green-700'
- : 'border-orange-400 bg-orange-50 text-orange-700'
+ ? 'border-green-500 bg-green-50 dark:bg-green-900/20 text-green-700 dark:text-green-400'
+ : 'border-orange-400 bg-orange-50 dark:bg-orange-900/20 text-orange-700 dark:text-orange-400'
: index === correctAnswer
- ? 'border-green-500 bg-green-50/50'
- : 'border-slate-100 opacity-50'
+ ? 'border-green-500 bg-green-50/50 dark:bg-green-900/10'
+ : 'border-slate-100 dark:border-slate-700 opacity-50'
}`}
>
{String.fromCharCode(65 + index)}
- {option}
+ {option}
))}
{selectedOption !== null && (
-
+
{isCorrect ? '🎉' : '💡'}
-
+
{isCorrect ? 'Bonne réponse !' : 'Oups, pas tout à fait...'}
-
+
{explanation || "Pas d'explication disponible."}
diff --git a/frontend/src/features/quiz/QuizPage.tsx b/frontend/src/features/quiz/QuizPage.tsx
index b494d9e..b3d9b2d 100644
--- a/frontend/src/features/quiz/QuizPage.tsx
+++ b/frontend/src/features/quiz/QuizPage.tsx
@@ -246,7 +246,7 @@ export function QuizPage() {
};
return (
-
+
{/* Pause Button */}
@@ -255,44 +255,44 @@ export function QuizPage() {
whileHover={{ scale: 1.05 }}
whileTap={{ scale: 0.95 }}
onClick={handlePause}
- className="absolute -top-2 right-0 text-slate-400 hover:text-indigo-600 font-bold text-sm bg-white px-4 py-2 rounded-full shadow-sm hover:shadow-md transition-all border border-slate-100 flex items-center gap-2"
+ className="absolute -top-2 right-0 text-slate-400 dark:text-slate-500 hover:text-indigo-600 dark:hover:text-indigo-400 font-bold text-sm bg-white dark:bg-slate-800 px-4 py-2 rounded-full shadow-sm hover:shadow-md transition-all border border-slate-100 dark:border-slate-700 flex items-center gap-2"
>
⏸ Pause & Quitter
)}
{loading && (
-
+
-
-
+
+
-
-
+
+
{[1, 2, 3, 4].map((i) => (
-
+
))}
-
Génération de votre quiz en cours...
+
Génération de votre quiz en cours...
)}
{error && (
-
+
⚠️
Une erreur est survenue
-
{error}
+
{error}
navigate('/dashboard')}
- className="mt-8 px-8 py-4 bg-white border-2 border-red-100 text-red-600 font-black rounded-2xl hover:bg-red-50 transition-all shadow-lg shadow-red-50 flex items-center justify-center gap-3"
+ className="mt-8 px-8 py-4 bg-white dark:bg-slate-800 border-2 border-red-100 dark:border-red-900/30 text-red-600 dark:text-red-400 font-black rounded-2xl hover:bg-red-50 dark:hover:bg-red-900/20 transition-all shadow-lg shadow-red-50 dark:shadow-none flex items-center justify-center gap-3"
>
Retour au tableau de bord
diff --git a/frontend/src/features/quiz/ResultCard.tsx b/frontend/src/features/quiz/ResultCard.tsx
index c7da20e..202e0c4 100644
--- a/frontend/src/features/quiz/ResultCard.tsx
+++ b/frontend/src/features/quiz/ResultCard.tsx
@@ -47,34 +47,34 @@ export function ResultCard({ score, totalQuestions, topic, onRetry, onNextSeries
if (isResumingSeries) {
message = "Prêt pour la suite ?";
- bgColor = "bg-blue-50";
- color = "text-blue-600";
+ bgColor = "bg-blue-50 dark:bg-blue-900/20";
+ color = "text-blue-600 dark:text-blue-400";
}
else if (percentage >= 80) {
message = "Excellent travail !";
- color = "text-green-600";
- bgColor = "bg-green-50";
+ color = "text-green-600 dark:text-green-400";
+ bgColor = "bg-green-50 dark:bg-green-900/20";
} else if (percentage >= 50) {
message = "Bravo, bel effort !";
- color = "text-soft-indigo";
- bgColor = "bg-indigo-50";
+ color = "text-soft-indigo dark:text-indigo-400";
+ bgColor = "bg-indigo-50 dark:bg-indigo-900/20";
}
return (
-
-
Quiz Terminé !
-
Sujet : {topic}
+
+
Quiz Terminé !
+
Sujet : {topic}
{percentage}%
-
{score} sur {totalQuestions} corrects
+
{score} sur {totalQuestions} corrects
{message}
@@ -82,14 +82,14 @@ export function ResultCard({ score, totalQuestions, topic, onRetry, onNextSeries
{onNextSeries && seriesInfo && seriesInfo.current < seriesInfo.total && (
)}
Tableau de bord
diff --git a/frontend/src/features/quiz/RevisionViewPage.tsx b/frontend/src/features/quiz/RevisionViewPage.tsx
index e34e471..350caeb 100644
--- a/frontend/src/features/quiz/RevisionViewPage.tsx
+++ b/frontend/src/features/quiz/RevisionViewPage.tsx
@@ -73,14 +73,14 @@ export function RevisionViewPage() {
}
return (
-
+
navigate('/dashboard')}
- className="flex items-center gap-2 px-4 py-2 bg-white border-2 border-slate-100 text-slate-500 font-bold rounded-xl hover:text-indigo-600 hover:border-indigo-100 transition-all shadow-sm"
+ className="flex items-center gap-2 px-4 py-2 bg-white dark:bg-slate-800 border-2 border-slate-100 dark:border-slate-700 text-slate-500 dark:text-slate-400 font-bold rounded-xl hover:text-indigo-600 dark:hover:text-indigo-400 hover:border-indigo-100 dark:hover:border-indigo-900 transition-all shadow-sm"
>
← Retour
@@ -88,22 +88,22 @@ export function RevisionViewPage() {
-
-
-
{revision.topic}
-
+
+
+
{revision.topic}
+
Révision du {new Date(revision.created_at).toLocaleDateString()}
-
+
{/* Synthesis Section */}
{revision.synthesis && (
-
+
✨ Résumé Magique
-
@@ -112,7 +112,7 @@ export function RevisionViewPage() {
{/* Tips Section */}
{revision.study_tips && (
-
+
💡 Conseils Métho
@@ -120,8 +120,8 @@ export function RevisionViewPage() {
try {
const tips = JSON.parse(revision.study_tips);
return Array.isArray(tips) ? tips.map((tip: string, idx: number) => (
-
-
{idx + 1}
+
+ {idx + 1}
{tip}
)) : null;
@@ -131,7 +131,7 @@ export function RevisionViewPage() {
)}
-
Contenu du Cours
+
Contenu du Cours
{revision.text_content}