Added a solution version for the MultipleChoice Exercise

This commit is contained in:
Tiago Ribeiro
2023-04-10 11:40:44 +01:00
parent 8c1d42f2d9
commit 06dbf1e5f6
5 changed files with 150 additions and 32 deletions

View File

@@ -57,7 +57,11 @@ export default function Listening({exam, onFinish}: Props) {
{exam.audio.repeatableTimes > 0 && (
<>{exam.audio.repeatableTimes <= timesListened && <span>You are no longer allowed to listen to the audio again.</span>}</>
)}
<span>AUDIO WILL GO HERE</span>
<audio preload="auto" controls autoPlay onPlay={() => setTimesListened((prev) => prev + 1)} onPause={() => alert("PAUSE")}>
<source src="https://www.sndup.net/hqvf/d" type="audio/mpeg" />
<source src="https://www.sndup.net/hqvf/m" type="audio/mpeg" />
Your browser does not support the audio element
</audio>
</div>
</>
);