diff --git a/src/editor-component.coffee b/src/editor-component.coffee index 32c068fd2..46b4b2177 100644 --- a/src/editor-component.coffee +++ b/src/editor-component.coffee @@ -403,7 +403,9 @@ EditorComponent = React.createClass editor.insertText(event.data) inputNode.value = event.data - event.preventDefault() + # If we prevent the insertion of a space character, then the browser + # interprets the spacebar keypress as a page-down command. + event.preventDefault() unless event.data is ' ' onInputFocused: -> @setState(focused: true)