2021-05-03 14:51:07 +00:00
|
|
|
{{/*
|
|
|
|
This template is intended to display a single thread in the context of a forum, the feed, or a similar layout.
|
|
|
|
|
|
|
|
It should be called with ThreadListItem.
|
|
|
|
*/}}
|
|
|
|
|
2021-05-03 22:45:17 +00:00
|
|
|
<div class="thread-list-item flex items-center ph3 pv2 {{ if .Unread }}unread{{ else }}read{{ end }} post-list-bg-odd {{ .Classes }}">
|
2021-05-03 14:51:07 +00:00
|
|
|
<img class="avatar-icon mr2" src="{{ .FirstUser.AvatarUrl }}">
|
|
|
|
<div class="flex-grow-1 overflow-hidden">
|
|
|
|
<div class="title nowrap truncate"><a href="{{ .Url }}">{{ .Title }}</a></div>
|
|
|
|
<div class="details">
|
2021-05-06 05:57:14 +00:00
|
|
|
<a class="user" href="{{ .FirstUser.ProfileUrl }}">{{ .FirstUser.Name }}</a> — {{ timehtml (relativedate .FirstDate) .FirstDate }}
|
2021-05-03 14:51:07 +00:00
|
|
|
</div>
|
|
|
|
{{ with .Content }}
|
|
|
|
<div class="mt2">
|
|
|
|
{{ . }}
|
|
|
|
</div>
|
|
|
|
{{ end }}
|
|
|
|
</div>
|
2021-05-03 22:45:17 +00:00
|
|
|
<div class="latestpost dn flex-ns flex-shrink-0 items-center ml2">
|
2021-05-03 14:51:07 +00:00
|
|
|
<img class="avatar-icon mr2" src="{{ .LastUser.AvatarUrl }}">
|
|
|
|
<div>
|
2021-05-06 05:57:14 +00:00
|
|
|
<div>Last post {{ timehtml (relativedate .LastDate) .LastDate }}</div>
|
2021-05-03 14:51:07 +00:00
|
|
|
<a class="user" href="{{ .LastUser.ProfileUrl }}">{{ .LastUser.Name }}</a>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div class="goto">
|
|
|
|
<a href="{{ .Url }}">»</a>
|
|
|
|
</div>
|
2021-05-25 13:12:20 +00:00
|
|
|
</div>
|