If you are looking for some code to disable the monitor or if you want the use an infrared sensor to detect when someone is in front of the mirror and only then turn it on, you can check my module https://github.com/thobach/MMM-Gestures.
A New Chapter for MagicMirror: The Community Takes the Lead
Read the statement by Michael Teeuw here.
Read the statement by Michael Teeuw here.
M