docbrown/app/views/articles/_widget_list_item.html.erb
Lisa Sy 6a79c85e6b
Update comments label in widget (#11196)
* Update comments label in widget

* Refactor pluralization
2020-11-02 11:17:19 -08:00

12 lines
415 B
Text

<a class="crayons-link crayons-link--contentful" href="<%= plucked_article[0] %>">
<%= plucked_article[1] %>
<% if show_comment_count %>
<div class="crayons-link__secondary">
<% if plucked_article[2] > 0 %>
<%= pluralize(plucked_article[2], "comment") %>
<% else %>
<span class="crayons-indicator crayons-indicator--accent">New</span>
<% end %>
</div>
<% end %>
</a>