Listening preview and some more patches
This commit is contained in:
@@ -1,8 +1,9 @@
|
||||
import Level from "@/exams/Level";
|
||||
import Listening from "@/exams/Listening";
|
||||
import Reading from "@/exams/Reading";
|
||||
import Writing from "@/exams/Writing";
|
||||
import { usePersistentStorage } from "@/hooks/usePersistentStorage";
|
||||
import { LevelExam, ReadingExam, WritingExam } from "@/interfaces/exam";
|
||||
import { LevelExam, ListeningExam, ReadingExam, WritingExam } from "@/interfaces/exam";
|
||||
import { User } from "@/interfaces/user";
|
||||
import { usePersistentExamStore } from "@/stores/examStore";
|
||||
import clsx from "clsx";
|
||||
@@ -34,6 +35,13 @@ const Popout: React.FC<{ user: User }> = ({ user }) => {
|
||||
state.setQuestionIndex(0);
|
||||
}} preview={true} />
|
||||
}
|
||||
{state.exam?.module == "listening" && state.exam.parts.length > 0 &&
|
||||
<Listening exam={state.exam as ListeningExam} onFinish={() => {
|
||||
state.setPartIndex(0);
|
||||
state.setExerciseIndex(-1);
|
||||
state.setQuestionIndex(0);
|
||||
}} preview={true} />
|
||||
}
|
||||
</div>
|
||||
</div>
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user