mlmym/templates/frontpage.html
Ryan Stafford d61a6f3bf1 dark mode
2023-07-02 20:37:36 -04:00

50 lines
1.8 KiB
HTML
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<!DOCTYPE html>
<head>
<title>{{ if and .Community (ne .Community.CommunityView.Community.Title "")}}{{.Community.CommunityView.Community.Title}}{{else if ne .CommunityName ""}}/c/{{.CommunityName}}{{ else if .User}}overview for {{.User.PersonView.Person.Name}}{{else}}{{ host .Host }}{{end}}</title>
<link rel="shortcut icon" href="/{{.Host}}/icon.jpg">
<link rel="stylesheet" href="/_/static/style.css?1">
<meta name="viewport" content="width=device-width, initial-scale=1" />
</head>
<body {{ if .Dark }}class="dark"{{end}}>
<noscript>
<style>
.expando-button {
display: none;
}
.comment .meta a.minimize {
display: none;
}
</style>
</noscript>
{{ template "nav.html" . -}}
<main>
{{ if or (contains .Sort "Top") (and (not .PostID) (not .User) (not .Community) (not .Activities) (eq .Op ""))}}
{{ template "menu.html" . }}
{{ end}}
{{ if .Error }}
<div class="error">{{.Error}}</div>
{{ end }}
{{ range .Posts }}
{{ template "post.html" . }}
{{ end }}
{{ if or (and (not .Op) (not .Activities) (not .Comments) (not .Posts) (not .Communities)) (and (not .Comments) .PostID) (and (not .Activities) (not .Query) .User) }}
<div class="error">there doesn't seem to be anything here</div>
{{ end }}
{{ if or .Query (eq .SearchType "Communities") (eq (len .Posts) 25) (and .Comments (and (eq .CommentCount 200) (gt (index .Posts 0).Counts.Comments .CommentCount))) (and .User (or (gt .User.PersonView.Counts.CommentCount 10) (gt .User.PersonView.Counts.PostCount 10))) }}
<div class="pager">
view more: {{if gt .Page 1 }}<a href="{{ .PrevPage }}"> prev</a>{{ end }} <a href="{{ .NextPage }}">next </a>
</div>
{{ end }}
{{ template "sidebar.html" . }}
</main>
<script src="/_/static/utils.js"></script>
</body>
</html>