fix chrome keyboard input issue

The keypress event has been changed to keydown instead
to deal with proper handling of the tab key.

Fixes #31