2012-09-06 10:18:26 +09:00
|
|
|
<template name="comment_item">
|
2014-08-12 16:16:44 +09:00
|
|
|
<li class="comment module comment-displayed" id="{{_id}}">
|
2012-10-01 10:59:08 +09:00
|
|
|
<div class="comment-body">
|
2014-09-16 12:12:48 +09:00
|
|
|
{{#if isDeleted}}
|
|
|
|
<div class="comment-deleted">This comment has been deleted.</div>
|
|
|
|
{{else}}
|
2012-09-10 18:12:04 +09:00
|
|
|
<div class="comment-content">
|
2012-10-01 11:45:18 +09:00
|
|
|
<div class="comment-actions {{#if upvoted}}upvoted{{else}}not-upvoted{{/if}} {{#if downvoted}}downvoted{{else}}not-downvoted{{/if}}">
|
2012-09-20 13:43:06 +09:00
|
|
|
<a class="upvote" href="#">
|
2012-09-10 18:12:04 +09:00
|
|
|
<i class="icon-up"></i>
|
2014-11-25 17:16:00 +09:00
|
|
|
<span>{{_ "upvote"}}</span>
|
2012-09-10 18:12:04 +09:00
|
|
|
</a>
|
2012-09-20 13:43:06 +09:00
|
|
|
<a class="downvote" href="#">
|
2012-09-10 18:12:04 +09:00
|
|
|
<i class="icon-down"></i>
|
2014-11-25 17:16:00 +09:00
|
|
|
<span>{{_ "downvote"}}</span>
|
2012-09-10 18:12:04 +09:00
|
|
|
</a>
|
|
|
|
</div>
|
2015-01-14 09:45:18 +09:00
|
|
|
<div class="comment-meta">
|
|
|
|
<div class="user-avatar">{{> avatar userId=userId shape="circle"}}</div>
|
|
|
|
<a class="comment-username" href="{{profileUrl}}">{{authorName}}</a>
|
|
|
|
<span class="comment-time">{{timeAgo ago}},</span>
|
|
|
|
<span class="points">{{upvotes}}</span> <span class="unit">points </span>
|
|
|
|
<a href="{{pathFor route='comment_reply' _id=_id}}" class="comment-permalink icon-link goto-comment">{{_ "link"}}</a>
|
|
|
|
{{#if canEdit this}}
|
|
|
|
| <a class="edit-link" href="{{pathFor route='comment_edit' _id=_id}}">{{_ "edit"}}</a>
|
|
|
|
{{/if}}
|
|
|
|
{{#if isAdmin}}
|
|
|
|
| <span>{{full_date}}</span>
|
|
|
|
{{/if}}
|
|
|
|
</div>
|
|
|
|
<div class="comment-main">
|
2014-08-31 16:11:48 +09:00
|
|
|
<div class="comment-text markdown">{{{htmlBody}}}</div>
|
2015-01-05 16:18:26 +09:00
|
|
|
<a href="{{pathFor route='comment_reply' _id=_id}}" class="comment-reply goto-comment">{{_ "reply"}}</a>
|
2012-09-10 18:12:04 +09:00
|
|
|
</div>
|
2012-08-22 23:40:09 -04:00
|
|
|
</div>
|
2014-09-16 12:12:48 +09:00
|
|
|
{{/if}}
|
2012-11-21 13:41:27 +09:00
|
|
|
{{#if showChildComments}}
|
2014-09-16 12:12:48 +09:00
|
|
|
<ul class="comment-children comment-list">
|
|
|
|
{{#each child_comments}}
|
|
|
|
{{#with this}}
|
|
|
|
{{> UI.dynamic template=comment_item}}
|
|
|
|
{{/with}}
|
|
|
|
{{/each}}
|
|
|
|
</ul>
|
2012-11-21 13:41:27 +09:00
|
|
|
{{/if}}
|
2012-08-22 23:40:09 -04:00
|
|
|
</div>
|
|
|
|
</li>
|
|
|
|
</template>
|