Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Fix textarea autoexpanding on iOS Safari, decrease maximum height

  • Loading branch information...
commit 3f460a438f1dd832540de3420a151b5e7ca8b72b 1 parent b143dc3
@tobscure tobscure authored
Showing with 4 additions and 4 deletions.
  1. +2 −2 js/conversation.js
  2. +2 −2 js/lib/jquery.autogrow.js
View
4 js/conversation.js
@@ -186,7 +186,7 @@ initReply: function() {
ETConversation.editingReply = false;
// Auto resize our reply textareas
- textarea.TextAreaExpander(200, 2000);
+ textarea.TextAreaExpander(200, 700);
// Disable the "post reply" button if there's not a draft. Disable the save draft button regardless.
if (!textarea.val()) $("#reply .postReply, #reply .discardDraft").disable();
@@ -628,7 +628,7 @@ editPost: function(postId) {
// Set up the text area.
var len = textarea.val().length;
- textarea.TextAreaExpander(200, 2000).focus().selectRange(len, len);
+ textarea.TextAreaExpander(200, 700).focus().selectRange(len, len);
new ETAutoCompletePopup(textarea, "@");
// Add click handlers to the cancel/submit buttons.
View
4 js/lib/jquery.autogrow.js
@@ -49,7 +49,7 @@
if (vlen != e.valLength || ewidth != e.boxWidth) {
// Save the scroll top position.
- var scrollTop = $(document).scrollTop();
+ //var scrollTop = $(document).scrollTop();
if (hCheck && (vlen < e.valLength || ewidth != e.boxWidth)) e.style.height = e.expandMin + "px";
var h = Math.max(e.expandMin, Math.min(e.scrollHeight, e.expandMax));
@@ -58,7 +58,7 @@
e.style.height = (h - parseInt($(e).css("padding-top")) - parseInt($(e).css("padding-bottom"))) + "px";
// Scroll back to where we were.
- $.scrollTo(scrollTop);
+ //$.scrollTo(scrollTop);
e.valLength = vlen;
e.boxWidth = ewidth;
Please sign in to comment.
Something went wrong with that request. Please try again.