lib/copy/admin/edit.html.erb in copy-0.0.41 vs lib/copy/admin/edit.html.erb in copy-0.1.0

- old
+ new

@@ -1,7 +1,11 @@ <div id="_copy"> <form class="_copy_edit_form" data-content-name="<%= @name %>" action="/_copy/<%= @name %>"> - <textarea name="content"><%= @doc %></textarea> + <% if @doc =~ /\n/ %> + <textarea name="content"><%=h @doc %></textarea> + <% else %> + <input type="text" name="content" value="<%=h @doc %>" /> + <% end %> <p class="_copy_footer _copy_footer_left"> <input class="_copy_submit" type="submit" value="Save" /> or <a class="_copy_cancel" href="#">cancel</a> </p> <p class="_copy_footer _copy_footer_right"> \ No newline at end of file