added some key bindings and document click js actions