Files
grecia/app/views/comments/_comment.html.erb

31 lines
923 B
Plaintext

<div class="row">
<div id="comment-<%= comment.id %>" class="comment small-12 column">
<%= avatar_image(comment.user, size: 32, class: 'left') %>
<div class="comment-body">
<span class="comment-info">
<span><%= comment.user.name %></span>&nbsp;&bullet;&nbsp;<%= time_ago_in_words(comment.created_at) %>
</span>
<p><%= comment.body %></p>
<span id="<%= dom_id(comment) %>_votes" class="comment-votes right">
<%= render 'comments/votes', comment: comment %>
</span>
<p class="reply">
<%= t("debates.comment.responses", count: comment.children_count) %>
<% if user_signed_in? %>
&nbsp;|&nbsp;
<%= render 'comments/form', {parent: comment, toggeable: true} %>
<% end %>
</p>
</div>
<div class="comment-children">
<%= render comment.children.reorder('id DESC, lft') %>
</div>
</div>
</div>