Skip to content

Conversation

@shubh1118
Copy link
Collaborator

Removed Exam 1 from the select dropdown.
Fixed exam problems in the filter view.
Added a header on the exam problems page to show which exam the problems belong to..

Removed Exam 1 from the select dropdown.
Added a header on the exam problems page to show which exam the problems belong to..
setProblemIdx(initialProblemIdx);
}
}, [initialProblemIdx]);

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

useEffects repeating for same task, use only one

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fixed

<Box sx={{ display: 'flex', justifyContent: 'space-between', width: '100%' }}>
<span>{t[type]}</span>
<Typography variant="caption" color="text.secondary">
({examcount})
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

rename this variable , very confusing for quiz, homework and uncategorized problems count

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fixed

Comment on lines 492 to 503
{/* TODO ALEA4-P3 solutions?.length > 0 && (
<Button variant="contained" onClick={() => setShowSolution(!showSolution)}>
{showSolution ? t.hideSolution : t.showSolution}
</Button>
)}*/}
{showSolution && (
<Box mb="10px">
{/* solutions.map((solution) => (
<div style={{ color: '#555' }} dangerouslySetInnerHTML={{__html:solution}}></div>
))*/}
</Box>
)}
Copy link
Collaborator

@abhishek2021005 abhishek2021005 Jan 19, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

donot remove comment at this place, this was supposed to be work in future TODO ALEA4-P3, put back all comments which are intentionally placed

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fixed

})
}
/>
{/* TODO ALEA4-P3
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

..

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fixed

Comment on lines 155 to 167
return [...knownOrder, ...rest];
return ['syllabus', 'adventurous'].filter((cat) => categoryMap[cat]?.length);
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

other categories apart from syllabus and adventurous are being ignored completely, look again

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fixed

.filter((p) => p.examRefs?.some((e) => isValidExamRef(e.examUri)))
.map((p) => p.problemId),
[problems]
);
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

do format , readability issue

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fixed

}

const problemUri = problemUris[problemIdx];
// TODO ALEA4-P3 const response = responses[problemIdx];
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

..

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fixed

Comment on lines 276 to 282
if (!problemUris.length) {
return (
<Typography sx={{ mt: 2 }} color="text.secondary">
No problems found for this filter.
</Typography>
);
}
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

using same thing at line 398, do consider different cases before early returning , as i can interpret earlier no problems found... was shown only in certain condition when tabIndex!=forme and !problemUris.length.
Do check again.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fixed

Comment on lines 381 to 394
filtered.forEach((u) => {
console.log(u, getProblemType(u)); //
});
let finalUris = filtered;

if (type === 'exam') {
finalUris = examProblemIds;
}

setProblemUris(finalUris);
setAllProblemUris(finalUris);
setIsSubmitted(finalUris.map(() => false));
setResponses(finalUris.map(() => undefined));
setProblemIdx(0);
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

do consider moving onApply functionality to a separate function

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fixed


{currentProblem?.examRefs
?.filter((exam) => isValidExamRef(exam.examUri))
.slice(0, 1)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

only first value is shown in exam chip, do talk with requirements manager to know exactly which exam to show if any problem is being asked in multiple exam.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

okay

Comment on lines 176 to 177
const cleanedD = dParam.replace(/-/g, ' ').replace(/\b\w/g, (c) => c.toUpperCase());
const examLabel = exam.term ? `${exam.term} ${cleanedD}`.trim() : cleanedD;
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

use formatExamLabel function defined in exam-problems.tsx here as well

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fixed

return result;
}

export const formatExamLabel = (examUri?: string, exam?: { number?: string; term?: string }) => {
Copy link
Collaborator

@abhishek2021005 abhishek2021005 Jan 19, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why is there need of passing other param exam object, nowhere it is being used while calling formatExamLabel .Also number and term both can be derived from examUri only

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

need to discuss....

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants