From 2d61a5d372b65b4a71a01a6ded48b3aa253e90aa Mon Sep 17 00:00:00 2001 From: Jan Lehnardt Date: Sat, 20 Feb 2010 07:09:57 +0000 Subject: Futon: Set rows for document source edit textarea to the number of rows in the source. git-svn-id: https://svn.apache.org/repos/asf/couchdb/trunk@912082 13f79535-47bb-0310-9956-ffa450edef68 --- share/www/script/futon.browse.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'share/www/script/futon.browse.js') diff --git a/share/www/script/futon.browse.js b/share/www/script/futon.browse.js index cc9c846e..408d34cc 100644 --- a/share/www/script/futon.browse.js +++ b/share/www/script/futon.browse.js @@ -826,7 +826,8 @@ $(this).html($("
").html($.futon.formatJSON(page.doc, {html: true})))
             .makeEditable({allowEmpty: false,
               createInput: function(value) {
-                return $("").enableTabInsertion();
+                var rows = value.split("\n").length;
+                return $("").enableTabInsertion();
               },
               prepareInput: function(input) {
                 $(input).makeResizable({vertical: true});
-- 
cgit v1.2.3