Due to historic reasons with a comment the list of all likes was sent to the frontend. This is needed just to detect if one of the likes is current users like. So if sending just the own like, the frontend can do it's job. When the frontend is refactured in any way, post and comment like handling should be improved.
54 lines
1.4 KiB
Handlebars
54 lines
1.4 KiB
Handlebars
<div id="{{guid}}">
|
|
<div class="img">
|
|
{{#linkToAuthor author}}
|
|
{{{personImage this "small" "small"}}}
|
|
{{/linkToAuthor}}
|
|
</div>
|
|
|
|
<div class="bd">
|
|
<div class="control-icons">
|
|
{{#if loggedIn}}
|
|
{{#if canRemove}}
|
|
<a href="#" class="delete comment_delete" title="{{t "delete"}}">
|
|
<i class="entypo-trash"></i>
|
|
</a>
|
|
{{else}}
|
|
<a href="#" data-type="Comment" class="comment_report" title="{{t "report.name"}}">
|
|
<i class="entypo-warning"></i>
|
|
</a>
|
|
{{/if}}
|
|
{{/if}}
|
|
</div>
|
|
|
|
<div>
|
|
{{#linkToAuthor author}}
|
|
{{name}}
|
|
{{/linkToAuthor}}
|
|
-
|
|
<a href="/posts/{{parent.id}}#{{guid}}" class="permalink_comment">
|
|
<time class="timeago" data-original-title="{{{localTime created_at}}}" datetime="{{created_at}}"></time>
|
|
</a>
|
|
<a href="/posts/{{parent.guid}}#{{guid}}" class="permalink gray" title="{{t "stream.permalink"}}">
|
|
<i class="entypo-link"></i>
|
|
</a>
|
|
</div>
|
|
|
|
<div class="collapsible comment-content markdown-content">
|
|
{{{text}}}
|
|
</div>
|
|
|
|
{{#if loggedIn}}
|
|
<div class="info">
|
|
<a href="#" class="like" rel='nofollow'>
|
|
{{~#if userLike~}}
|
|
{{~t "stream.unlike"~}}
|
|
{{~else~}}
|
|
{{~t "stream.like"~}}
|
|
{{~/if~}}
|
|
</a>
|
|
</div>
|
|
{{/if}}
|
|
<div class="likes likes-on-comment"> </div>
|
|
|
|
</div>
|
|
</div>
|