From: David ‘Bombe’ Roden Date: Tue, 29 May 2012 20:36:18 +0000 (+0200) Subject: Replace single-line inputs with textareas in non-JS mode. X-Git-Tag: 0.8.2^2~12 X-Git-Url: https://git.pterodactylus.net/?a=commitdiff_plain;h=d64c7c75d5246b08af3b2b5aa3e6fd0190b2fdf1;p=Sone.git Replace single-line inputs with textareas in non-JS mode. This fixes #49. --- diff --git a/src/main/resources/static/javascript/sone.js b/src/main/resources/static/javascript/sone.js index 6077049..2063576 100644 --- a/src/main/resources/static/javascript/sone.js +++ b/src/main/resources/static/javascript/sone.js @@ -1865,6 +1865,14 @@ var currentSoneMenuTimeoutHandler; $(document).ready(function() { + /* rip out the status update textarea. */ + $("#sone .rip-out").each(function() { + var oldElement = $(this); + newElement = $(""); + newElement.attr("class", oldElement.attr("class")).attr("name", oldElement.attr("name")); + oldElement.before(newElement).remove(); + }); + /* this initializes the status update input field. */ getTranslation("WebInterface.DefaultText.StatusUpdate", function(defaultText) { registerInputTextareaSwap("#sone #update-status .status-input", defaultText, "text", false, false); diff --git a/src/main/resources/templates/include/updateStatus.html b/src/main/resources/templates/include/updateStatus.html index 881aca4..dde0486 100644 --- a/src/main/resources/templates/include/updateStatus.html +++ b/src/main/resources/templates/include/updateStatus.html @@ -10,6 +10,6 @@
- + diff --git a/src/main/resources/templates/include/viewPost.html b/src/main/resources/templates/include/viewPost.html index 396fa6e..87a2656 100644 --- a/src/main/resources/templates/include/viewPost.html +++ b/src/main/resources/templates/include/viewPost.html @@ -133,7 +133,7 @@
- +