Update: color changes to the question number when it has been answered

This commit is contained in:
percyfikri 2024-10-24 10:05:43 +07:00
parent 5f0dafd8a9
commit ebbadf5e02

View File

@ -560,7 +560,6 @@ export default function AssessmentPage() {
{/* MIDDLE */}
{/* Pertanyaan */}
{/* <div className="w-full ml-64"></div> */}
<div className="ml-64 mr-60 flex-1 overflow-y-auto h-full">
<Stack gap="sm" style={{ flex: 1 }}>
<Text className="text-2xl font-bold ml-6">
@ -753,10 +752,11 @@ export default function AssessmentPage() {
<div key={questionId} className="flex justify-center relative">
<button
className={`w-9 h-9 border rounded-sm flex items-center justify-center relative text-md
${flaggedQuestions[questionId] ? "text-black" : "bg-transparent text-black"}`}
${answers[questionId] ? "bg-blue-500 text-white" : "bg-transparent text-black"}
${flaggedQuestions[questionId] ? "border-black" : ""}`}
onClick={() => scrollToQuestion(questionId)}
>
{questionNumber} {/* Menampilkan nomor pertanyaan yang sudah difilter */}
{questionNumber}
</button>
{flaggedQuestions[questionId] && (