github.com/Azareal/Gosora@v0.0.0-20210729070923-553e66b59003/templates/topic_posts.html (about)

     1  <div class="rowblock post_container" aria-label="{{lang "topic.current_page_aria"}}" style="overflow:hidden;">{{range .ItemList}}
     2  {{if .ActionType}}
     3  	<article {{scope "post_action"}} id="post-{{.ID}}" itemscope itemtype="http://schema.org/CreativeWork" class="rowitem passive deletable_block editable_parent post_item action_item">
     4  		<span class="action_icon">{{.ActionIcon}}</span>
     5  		<span itemprop="text">{{.ActionType}}</span>
     6  	</article>
     7  {{else}}
     8  	<article {{scope "post"}} id="post-{{.ID}}" itemscope itemtype="http://schema.org/CreativeWork" class="rowitem passive deletable_block editable_parent post_item {{.ClassName}}" style="background-image:url({{.Avatar}}),url(/s/{{$.Header.Theme.Name}}/post-avatar-bg.jpg);background-position:0px {{if le .ContentLines 5}}-1{{end}}0px;background-repeat:no-repeat,repeat-y;">
     9  		{{/** TODO: We might end up with <br>s in the inline editor, fix this **/}}
    10  		<div class="editable_block user_content" itemprop="text">{{.ContentHtml}}</div>
    11  		{{if $.CurrentUser.Loggedin}}<div class="auto_hide edit_source">{{.Content}}</div>{{end}}
    12  
    13  		<span class="controls{{if .LikeCount}} has_likes{{end}}">
    14  
    15  		<a href="{{.UserLink}}" class="username real_username" rel="author">{{.CreatedByName}}</a>&nbsp;&nbsp;
    16  		{{if $.CurrentUser.Perms.LikeItem}}{{if ne $.CurrentUser.ID .CreatedBy}}{{if .Liked}}<a href="/reply/unlike/submit/{{.ID}}?s={{$.CurrentUser.Session}}" class="mod_button" title="{{lang "topic.post_unlike_tooltip"}}" aria-label="{{lang "topic.post_unlike_aria"}}"><button class="username like_label remove_like"></button></a>{{else}}<a href="/reply/like/submit/{{.ID}}?s={{$.CurrentUser.Session}}" class="mod_button" title="{{lang "topic.post_like_tooltip"}}" aria-label="{{lang "topic.post_like_aria"}}"><button class="username like_label add_like"></button></a>{{end}}{{end}}{{end}}
    17  
    18  		<a href="" class="mod_button quote_item" title="{{lang "topic.quote_tooltip"}}" aria-label="{{lang "topic.quote_aria"}}"><button class="username quote_label"></button></a>
    19  
    20  		{{if not $.Topic.IsClosed or $.CurrentUser.Perms.CloseTopic}}
    21  		{{if $.CurrentUser.Perms.EditReply}}<a href="/reply/edit/submit/{{.ID}}?s={{$.CurrentUser.Session}}" class="mod_button" title="{{lang "topic.post_edit_tooltip"}}" aria-label="{{lang "topic.post_edit_aria"}}"><button class="username edit_item edit_label"></button></a>{{end}}
    22  		{{end}}
    23  
    24  		{{if .Deletable}}<a href="/reply/delete/submit/{{.ID}}?s={{$.CurrentUser.Session}}" class="mod_button" title="{{lang "topic.post_delete_tooltip"}}" aria-label="{{lang "topic.post_delete_aria"}}"><button class="username delete_item delete_label"></button></a>{{end}}
    25  		{{if $.CurrentUser.Perms.ViewIPs}}<a class="mod_button" href='/users/ips/?ip={{.IP}}' title="{{lang "topic.post_ip_tooltip"}}" aria-label="The poster's IP is {{.IP}}"><button class="username ip_label"></button></a>{{end}}
    26  		<a href="/report/submit/{{.ID}}?s={{$.CurrentUser.Session}}&amp;type=reply" class="mod_button report_item" title="{{lang "topic.post_flag_tooltip"}}" aria-label="{{lang "topic.post_flag_aria"}}" rel="nofollow"><button class="username report_item flag_label"></button></a>
    27  
    28  		<a class="username hide_on_micro like_count">{{.LikeCount}}</a><a class="username hide_on_micro like_count_label" title="{{lang "topic.post_like_count_tooltip"}}"></a>
    29  
    30  		{{if .Tag}}<a class="username hide_on_micro user_tag">{{.Tag}}</a>{{else}}<a class="username hide_on_micro level" aria-label="{{lang "topic.post_level_aria"}}" title="{{lang "topic.post_level_tooltip"}}">{{.Level}}</a><a class="username hide_on_micro level_label" title="{{lang "topic.post_level_tooltip"}}"></a>{{end}}
    31  
    32  		</span>
    33  	</article>
    34  {{end}}
    35  {{end}}</div>