diff src/edit.js.luan @ 33:4fdc4ec0050b

upload with uploadcare
author Franklin Schmidt <fschmidt@gmail.com>
date Mon, 01 Aug 2022 22:50:16 -0600
parents 66fd3784e60e
children 0c1b820fff34
line wrap: on
line diff
--- a/src/edit.js.luan	Fri Jul 29 13:57:20 2022 -0600
+++ b/src/edit.js.luan	Mon Aug 01 22:50:16 2022 -0600
@@ -14,11 +14,11 @@
 	post = Post.get_by_id(post) or error()
 	Io.stdout = Http.response.text_writer()
 %>
-let postDiv = document.querySelector('[post="<%=post.id%>"]');
-postDiv.querySelector('[output]').style.display = 'none';
-postDiv.querySelector('[edit]').innerHTML = document.querySelector('[hidden][edit]').innerHTML;
-let textarea = postDiv.querySelector('textarea');
-textarea.innerHTML = <%= json_string(html_encode(post.content)) %>;
-textarea.focus();
+	let postDiv = document.querySelector('[post="<%=post.id%>"]');
+	postDiv.querySelector('[output]').style.display = 'none';
+	postDiv.querySelector('[edit]').innerHTML = document.querySelector('[hidden][edit]').innerHTML;
+	let textarea = postDiv.querySelector('textarea');
+	textarea.innerHTML = <%= json_string(html_encode(post.content)) %>;
+	textarea.focus();
 <%
 end