29 lines
1.2 KiB
Text
29 lines
1.2 KiB
Text
<% if(typeof(all_comments_loaded) == 'undefined' || !all_comments_loaded) { %>
|
|
<ul class="show_comments <%= comments_count <= 3 ? 'hidden' : '' %>">
|
|
<li>
|
|
<a href="/posts/<%= id %>/comments" class="toggle_post_comments">
|
|
<%= Diaspora.I18n.t('stream.more_comments', {count : comments_count - 3}) %>
|
|
</a>
|
|
</li>
|
|
</ul>
|
|
<% } %>
|
|
|
|
<ul class="comments"> </ul>
|
|
|
|
<% if(current_user) { %>
|
|
<div class="new_comment_form_wrapper <%= comments_count > 0 ? '' : 'hidden' %>">
|
|
<form accept-charset="UTF-8" action="/posts/<%= id %>/comments" class="new_comment" id="new_comment_on_<%= id %>" method="post">
|
|
<a href="/people/<%= current_user.guid %>">
|
|
<img src="<%= current_user.avatar.small %>" class="avatar" data-person-id="<%= current_user.id %>"/>
|
|
</a>
|
|
|
|
<p>
|
|
<label for="comment_text_on_<%= id %>"><%= Diaspora.I18n.t('stream.comment') %></label>
|
|
<textarea class="comment_box" id="comment_text_on_<%= id %>" name="text" rows="2" />
|
|
</p>
|
|
<div class="submit_button">
|
|
<input class="button creation" id="comment_submit_<%= id %>" name="commit" type="submit" value="<%= Diaspora.I18n.t('stream.comment') %>" />
|
|
</div>
|
|
</form>
|
|
</div>
|
|
<% } %>
|