Refactored. Added tests for key. Key click works (sort of).
Timer is broken - causes reset; reason unknown.