From dfe8c3680499d6a8659fb46c6c531e392ef791ba Mon Sep 17 00:00:00 2001 From: JubaAzul <118773284+JubaAzul@users.noreply.github.com> Date: Fri, 24 Jan 2025 20:19:59 -0500 Subject: [PATCH] =?UTF-8?q?Feedback=20g=C3=A9n=C3=A9ral=20=C3=A0=20la=20qu?= =?UTF-8?q?estion=20:=20formules=20KateX=20pas=20prises=20en=20charge=20da?= =?UTF-8?q?ns=20l'affichage=20du=20quiz=20Fixes=20#202?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../MultipleChoiceQuestion/MultipleChoiceQuestion.tsx | 2 +- .../Questions/NumericalQuestion/NumericalQuestion.tsx | 6 +++--- .../Questions/ShortAnswerQuestion/ShortAnswerQuestion.tsx | 4 ++-- .../Questions/TrueFalseQuestion/TrueFalseQuestion.tsx | 4 ++-- 4 files changed, 8 insertions(+), 8 deletions(-) diff --git a/client/src/components/Questions/MultipleChoiceQuestion/MultipleChoiceQuestion.tsx b/client/src/components/Questions/MultipleChoiceQuestion/MultipleChoiceQuestion.tsx index 9c18605..289a7d5 100644 --- a/client/src/components/Questions/MultipleChoiceQuestion/MultipleChoiceQuestion.tsx +++ b/client/src/components/Questions/MultipleChoiceQuestion/MultipleChoiceQuestion.tsx @@ -72,7 +72,7 @@ const MultipleChoiceQuestion: React.FC = (props) => { })} {globalFeedback && showAnswer && ( -
{globalFeedback}
+
)} {!showAnswer && handleOnSubmitAnswer && ( diff --git a/client/src/components/Questions/NumericalQuestion/NumericalQuestion.tsx b/client/src/components/Questions/NumericalQuestion/NumericalQuestion.tsx index 7a9cec7..444a794 100644 --- a/client/src/components/Questions/NumericalQuestion/NumericalQuestion.tsx +++ b/client/src/components/Questions/NumericalQuestion/NumericalQuestion.tsx @@ -2,7 +2,7 @@ import React, { useState } from 'react'; import '../questionStyle.css'; import { Button, TextField } from '@mui/material'; -import textType from '../../GiftTemplate/templates/TextType'; +import textType, { formatLatex } from '../../GiftTemplate/templates/TextType'; import { TextFormat } from '../../GiftTemplate/templates/types'; import DOMPurify from 'dompurify'; @@ -40,7 +40,7 @@ const NumericalQuestion: React.FC = (props) => { {showAnswer ? ( <>
{correctAnswer}
- {globalFeedback &&
{globalFeedback}
} + {globalFeedback &&
} ) : ( <> @@ -56,7 +56,7 @@ const NumericalQuestion: React.FC = (props) => { /> {globalFeedback && showAnswer && ( -
{globalFeedback}
+
)} {handleOnSubmitAnswer && ( {globalFeedback && showAnswer && ( -
{globalFeedback}
+
)} {!showAnswer && handleOnSubmitAnswer && (