diff options
author | knotteye <knotteye@airmail.cc> | 2021-07-02 14:20:16 -0500 |
---|---|---|
committer | knotteye <knotteye@airmail.cc> | 2021-07-02 14:20:16 -0500 |
commit | faae38726dd804e3246514d88f93794c23a0cdb2 (patch) | |
tree | 4671606919340098b81c398e8478ba616a0432b1 /static/anews.html | |
parent | ad5f4e9ff7e7ab0abab4a964cbf1626d0cdc3365 (diff) |
show only the last 3 news items on index, link to a page with all news items
Diffstat (limited to 'static/anews.html')
-rw-r--r-- | static/anews.html | 44 |
1 files changed, 44 insertions, 0 deletions
diff --git a/static/anews.html b/static/anews.html new file mode 100644 index 0000000..6527ce5 --- /dev/null +++ b/static/anews.html @@ -0,0 +1,44 @@ +{{ define "header" }} +<title>{{ .Title }}</title> +<meta name="description" content="{{ .PreferredUsername }} is a federated image board based on activitypub. The current version of the code running the server is still a work in progress, expect a bumpy ride for the time being. Get the server code here: https://github.com/FChannel0."> + +<meta property="og:locale" content="en_US" /> +<meta property="og:type" content="website" /> +<meta property="og:url" content="{{ .Board.Domain }}"> +<meta property="og:site_name" content="{{ .Board.Actor.PreferredUsername }}" /> + +<meta property="og:title" content="{{ .Title }}"> +<meta property="og:description" content="{{ .PreferredUsername }} is a federated image board based on activitypub. The current version of the code running the server is still a work in progress, expect a bumpy ride for the time being. Get the server code here: https://github.com/FChannel0."> + +<meta name="twitter:title" content="{{ .Title }}"> +<meta name="twitter:description" content="{{ .PreferredUsername }} is a federated image board based on activitypub. The current version of the code running the server is still a work in progress, expect a bumpy ride for the time being. Get the server code here: https://github.com/FChannel0."> +<meta name="twitter:card" content="summary_large_image"> + +{{ end }} + +{{ define "top" }}{{ end }} +{{ define "content" }} +<div style="text-align: center; max-width: 800px; margin: 0 auto;"> + <h1>{{ .Title }}</h1> + + <div style="margin-top:50px;"> + <table align="center" style="text-align: left;"> + + {{ range $i, $e := .NewsItems }} + <tr> + <td><a href="/news/{{.Time}}">{{unixtoreadable $e.Time}} - {{$e.Title}}</a> + {{ if eq $i 0 }} + <br><p>{{$e.Content}}</p> + {{ end }} + </td> + </tr> + {{ end }} + </table> + </div> + +</div> +{{ end }} +{{ define "bottom" }}{{ end }} + +{{ define "script" }} +{{ end }} |