brainpm / bpm-webplayer

display interactive content bundled by brainpm (bpm) in a web browser
0 stars 0 forks source link

idle detection #37

Open regular opened 9 years ago

regular commented 9 years ago

setTimeout() of say 20 seconds on scroll and mousemove. If the timer hits, the user is considered idle and we display a little idle icon in the top bar.

idle start and idle end events are written to the logdb.

needs #36 to be implemented first, otherwise a user consuming media will be considered idle.

Motivation

This allows us to calculate the average time it takes to read an episode or to reach a goal. We can give this information to new students when they set their goal.

For example:

"Become a web developer! (takes an average of 45 hours)

This does not take into account time spent on external sites like Codecademy, but if they provide such numbers, we can sum them up.