Skip to content
Snippets Groups Projects
Commit bc1c841f authored by BURCKEL MAXIME's avatar BURCKEL MAXIME
Browse files

merge

parent 020cb35d
Branches
Tags
No related merge requests found
......@@ -53,6 +53,7 @@ export default function QuizQuestionPage({
useEffect(() => {
if (timer && !isSubmitted) {
console.log("timer", timer);
if (timer < 0) return;
const intervalId = setInterval(() => {
......@@ -87,6 +88,25 @@ export default function QuizQuestionPage({
<FaTimes className="text-white" />
</button>
{mode === "timer" ? (
<div className="absolute right-40 top-44">
<CircularProgressbar
className="w-32 h-32"
value={timerPercentage}
text={String(timer)}
background={true}
backgroundPadding={0}
styles={buildStyles({
backgroundColor: "#fff",
textColor: "#00A4D7",
pathColor: getPathColor(timerPercentage),
trailColor: "rgba(0, 195, 255, 0.5)",
textSize: "22px",
})}
/>
</div>
) : null}
{/* Section principale */}
<div className="flex-grow flex flex-col items-center">
<div className="absolute top-4 center-4 flex items-center space-x-2 bg-white text-[#000] rounded-full px-4 py-1 font-bold text-lg shadow-md">
......@@ -183,6 +203,9 @@ export default function QuizQuestionPage({
{index + 1}. {teamName}
</span>
<span className="text-sm">{score} pts</span>
<p>
{"timer :"} {timer}
</p>
</li>
))}
</ul>
......
......@@ -217,6 +217,12 @@ export default function QuizQuestionPage() {
const correctAnswerReveal = currentQuestion.answers.find(
(reponse) => reponse.id == correctAnswer?.correctAnswer
);
console.log(
"verif : ",
correctAnswerReveal.id,
"avec : ",
option.id
);
return (
<AnswerOption
key={index}
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment