all repos — honk @ 1d1b066518c7e2484f72c92e57a873b61b0ae770

my fork of honk

views/honkpage.html (view raw)

 1{{ template "header.html" . }}
 2<main>
 3<div class="info" id="infobox">
 4<div id="srvmsg">
 5{{ if .Name }}
 6<p>{{ .Name }} <span style="margin-left:1em;"><a href="/u/{{ .Name }}/rss">rss</a></span>
 7<p>{{ .WhatAbout }}
 8{{ end }}
 9<p>{{ .ServerMessage }}
10
11<form action="/q" method="GET">
12<input type="text" name="q" autocomplete=off size=10 id="searchbox" placeholder="search">
13</form>
14
15</div>
16{{ if .HonkCSRF }}
17{{ template "honkform.html" . }}
18<script src="/honkpage.js{{ .JSParam }}" defer data-csrf="{{ .HonkCSRF }}" data-pagename="{{ .PageName }}" data-pagearg="{{ .PageArg }}" data-tophid="{{ .TopHID }}" data-srvmsg="{{ .ServerMessage }}"></script>
19{{ end }}
20{{ if .LocalJSParam }}
21<script src="/local.js{{ .LocalJSParam }}" defer></script>
22{{ end }}
23</div>
24{{ if and .HonkCSRF (not .IsPreview) }}
25<div class="info" id="refreshbox">
26<p><button id="honkrefresher" class="refresh">refresh</button><span></span>
27<button id="newerscroller" class="scrolldown">scroll down</button>
28</div>
29{{ end }}
30<div id="honksonpage">
31<div>
32{{ $BonkCSRF := .HonkCSRF }}
33{{ $IsPreview := .IsPreview }}
34{{ $MapLink := .MapLink }}
35{{ $Badonk := .User.Options.Reaction }}
36{{ $OmitImages := .User.Options.OmitImages }}
37{{ range .Honks }}
38{{ template "honk.html" map "Honk" . "MapLink" $MapLink "BonkCSRF" $BonkCSRF "IsPreview" $IsPreview "Badonk" $Badonk "OmitImages" $OmitImages }}
39{{ end }}
40</div>
41</div>
42</main>