* Try hiding low-quality comments * Message indicating when negative comments are being hidden * Adjust comment show count for logged-out visitors * Remove unusued comments_to_show_count from article decorator * Remove unusued comments_to_show_count from podcast episode decorator * Add test for hidden negative comment * Update spec/system/articles/user_visits_an_article_spec.rb Co-authored-by: Fernando Valverde <fernando@fdo.cr> * Don't create twice; do test logged-in and -out * Comment caching needs to account for signed-in status Co-authored-by: Fernando Valverde <fernando@fdo.cr>
18 lines
862 B
Text
18 lines
862 B
Text
<div class="align-center">
|
|
<% if @comments_to_show_count && @article.comments_count > @comments_to_show_count %>
|
|
<div class="mb-4">
|
|
<a class="crayons-btn crayons-btn--secondary w-100" href="<%= @article.path %>/comments">
|
|
<%= t("views.comments.parent.view_full", count: @article.comments_count) %>
|
|
</a>
|
|
</div>
|
|
<% end %>
|
|
|
|
<% unless all_comments_visible?(@article) %>
|
|
<p class="fs-s color-base-60 mb-4">
|
|
<%= t("views.comments.visible_signed_in.text_html", sign_in: link_to(t("views.comments.visible_signed_in.sign_in"), "/enter")) if any_hidden_negative_comments?(@article) %>
|
|
<%= t("views.comments.hidden.text_html", info: link_to(t("views.comments.hidden.info"), "/faq")) if @article.any_comments_hidden %>
|
|
</p>
|
|
<% end %>
|
|
|
|
<%= render "articles/conduct_and_abuse_actions", page: "articles_show" %>
|
|
</div>
|