diff --git a/public/javascripts/app/views/post-viewer/new_comment.js b/public/javascripts/app/views/post-viewer/new_comment.js index eab44360e4747f4c8b5bccba944a37a11bfc0d1b..c42de35c90beaece22ce1f24c50dddcd47f5d473 100644 --- a/public/javascripts/app/views/post-viewer/new_comment.js +++ b/public/javascripts/app/views/post-viewer/new_comment.js @@ -30,12 +30,8 @@ app.views.PostViewerNewComment = app.views.Base.extend({ this.model.trigger("interacted") this.toggleFormState() this.$("textarea").val("") - this.$("textarea").css('height', '18px') - - /* scroll to bottom without animation */ - $(this.scrollableArea).scrollTop($(this.scrollableArea).prop("scrollHeight")) - - this.$("textarea").focus() + .css('height', '18px') + .focus() }, toggleFormState : function() { @@ -43,7 +39,7 @@ app.views.PostViewerNewComment = app.views.Base.extend({ }, scrollToBottom : function() { - $(this.scrollableArea).animate({ scrollTop: $(this.scrollableArea).prop("scrollHeight") }, 1000); + $(this.scrollableArea).scrollTop($(this.scrollableArea).prop("scrollHeight")) } })