Time alerts during quiz

Re: Time alerts during quiz

by Tim Hunt -
Number of replies: 0
Picture of Core developers Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Peer reviewers Picture of Plugin developers

Just to say that the quiz countdown timer is one of those things on my list of thing that need to be improved when I get a round tuit.

Doing what Otoniel asks for well is a tricky balance. On the one hand you want the student to notice that time is getting short. On the other hand, you don't want to completely interrupt their thoughts. (So, I think a plan JavaScript alert is on the side of being too invasive.)

In addition to extra JS, the other thing you can hook into is that inside the last 100 seconds, Moodle puts a CSS class on the timer like class="timeleft99" (https://github.com/moodle/moodle/blob/master/mod/quiz/module.js#L114). Moodle itself only hooks into this for the last 15 seconds: https://github.com/moodle/moodle/blob/master/mod/quiz/styles.css#L209, but you could do more. (I have not idea why it is just 15 seconds. It has just been like that for many years.)

Average of ratings: Useful (3)