25 lines
1.0 KiB
Plaintext
25 lines
1.0 KiB
Plaintext
<span class="js-flag-actions">
|
|
<%= render "shared/flag_actions", flaggable: comment, divider: true %>
|
|
</span>
|
|
|
|
<span class="js-moderation-actions">
|
|
<% if can? :hide, comment %>
|
|
<span class="divider"> • </span>
|
|
<% if comment.author == current_user %>
|
|
<%= link_to t("comments.actions.delete"),
|
|
hide_comment_path(comment),
|
|
method: :put, remote: true, class: "delete-comment",
|
|
data: { confirm: t("comments.actions.confirm_delete") } %>
|
|
<% else %>
|
|
<%= link_to t("admin.actions.hide").capitalize, hide_moderation_comment_path(comment),
|
|
method: :put, remote: true, data: { confirm: t("admin.actions.confirm") } %>
|
|
<% end %>
|
|
<% end %>
|
|
|
|
<% if can? :hide, comment.user %>
|
|
<span class="divider"> • </span>
|
|
<%= link_to t("admin.actions.hide_author").capitalize, hide_moderation_user_path(comment.user_id),
|
|
method: :put, data: { confirm: t("admin.actions.confirm") } %>
|
|
<% end %>
|
|
</span>
|