liebling icon indicating copy to clipboard operation
liebling copied to clipboard

Displaying comments on tiles

Open wftl opened this issue 1 year ago • 1 comments

Is there a way to do this? I'm subscribed to the GHOST Pro tier that, theoretically, allows me to edit a theme. Ideally, it would just be a simple line above the date and time to read. For example.

 7 Comments
 8 days ago    *    5 min read

Just something like that would be awesome. Thanks!

wftl avatar Mar 22 '23 14:03 wftl

You can edit partials/loop.hbs file by adding this line 39:

{{comment_count empty="" singular="comment" plural="comments" autowrap="span" class=""}}

but it will add the same line as published date

or If you need a position above the date and time to read, you can wrap with div

<div>
  {{comment_count empty="0 comment" singular="comment" plural="comments" autowrap="span" class=""}}
  <div  class="m-article-card__timestamp">
    <span>{{date published_at timeago="true"}}</span>
    <span>&bull;</span>
    <span>{{reading_time minute=(t "1 min read") minutes=(t "% min read")}}</span>
  </div>
</div>

Reference : https://ghost.org/docs/themes/helpers/comments/

Phonbopit avatar Mar 22 '23 15:03 Phonbopit