recook some forms

This commit is contained in:
Ted Unangst 2019-10-08 02:06:09 -04:00
parent 0010d62d63
commit 4382a930f9
4 changed files with 59 additions and 34 deletions

View File

@ -5,27 +5,37 @@
Honk Filtering and Censoring System
<form action="/savehfcs" method="POST">
<input type="hidden" name="CSRF" value="{{ .FilterCSRF }}">
<hr>
<h3>new filter</h3>
<p><input tabindex=1 type="text" name="name" value="" autocomplete=off> - name
<p><label for="name">filter name:</label><br>
<input tabindex=1 type="text" name="name" value="" autocomplete=off>
<hr>
<h3>match</h3>
<p><input tabindex=1 type="text" name="actor" value="" autocomplete=off> - who/where
<p><span><label for="incaud">include audience:</label>
<input tabindex=1 type="checkbox" id="incaud" name="incaud" value="yes"><span></span></span>
<p><input tabindex=1 type="text" name="filttext" value="" autocomplete=off> - text
<p><span><label for="isannounce">is announce:</label>
<input tabindex=1 type="checkbox" id="isannounce" name="isannounce" value="yes"><span></span></span>
<p><input tabindex=1 type="text" name="announceof" value="" autocomplete=off> - announce of
<p><label for="actor">who or where:</label><br>
<input tabindex=1 type="text" name="actor" value="" autocomplete=off>
<p><span><label class=button for="incaud">include audience:
<input tabindex=1 type="checkbox" id="incaud" name="incaud" value="yes"><span></span></label></span>
<p><label for="filttext">text matches:</label><br>
<input tabindex=1 type="text" name="filttext" value="" autocomplete=off>
<p><span><label class=button for="isannounce">is announce:
<input tabindex=1 type="checkbox" id="isannounce" name="isannounce" value="yes"><span></span></label></span>
<p><label for="announceof">announce of:</label><br>
<input tabindex=1 type="text" name="announceof" value="" autocomplete=off>
<hr>
<h3>action</h3>
<p><span><label for="doreject">reject:</label>
<input tabindex=1 type="checkbox" id="doreject" name="doreject" value="yes"><span></span></span>
<span><label for="doskipmedia">skip media:</label>
<input tabindex=1 type="checkbox" id="doskipmedia" name="doskipmedia" value="yes"><span></span></span>
<span><label for="dohide">hide:</label>
<input tabindex=1 type="checkbox" id="dohide" name="dohide" value="yes"><span></span></span>
<span><label for="docollapse">collapse:</label>
<input tabindex=1 type="checkbox" id="docollapse" name="docollapse" value="yes"><span></span></span>
<p><input tabindex=1 type="text" name="filtrewrite" value="" autocomplete=off> - rewrite
<p><input tabindex=1 type="text" name="filtreplace" value="" autocomplete=off> - replace
<p class=buttonarray><span><label class=button for="doreject">reject:
<input tabindex=1 type="checkbox" id="doreject" name="doreject" value="yes"><span></span></label></span>
<span><label class=button for="doskipmedia">skip media:
<input tabindex=1 type="checkbox" id="doskipmedia" name="doskipmedia" value="yes"><span></span></label></span>
<span><label class=button for="dohide">hide:
<input tabindex=1 type="checkbox" id="dohide" name="dohide" value="yes"><span></span></label></span>
<span><label class=button for="docollapse">collapse:
<input tabindex=1 type="checkbox" id="docollapse" name="docollapse" value="yes"><span></span></label></span>
<p><label for="rewrite">rewrite:</label><br>
<input tabindex=1 type="text" name="filtrewrite" value="" autocomplete=off>
<p><label for="replace">replace:</label><br>
<input tabindex=1 type="text" name="filtreplace" value="" autocomplete=off>
<hr>
<p><button>impose your will</button>
</form>
</div>

View File

@ -3,13 +3,16 @@
<div class="info">
<p>
<form action="/submithonker" method="POST">
<span class="title">add new honker</span>
<h3>add new honker</h3>
<input type="hidden" name="CSRF" value="{{ .HonkerCSRF }}">
<p><input tabindex=1 type="text" name="url" value="" autocomplete=off> - url
<p><input tabindex=1 type="text" name="name" value="" placeholder="optional" autocomplete=off> - name
<p><input tabindex=1 type="text" name="combos" value="" placeholder="optional"> - combos
<p><span><label for="peep">just peeping:</label>
<input tabindex=1 type="checkbox" id="peep" name="peep" value="peep"><span></span></span>
<p><label for=url>url:</label><br>
<input tabindex=1 type="text" name="url" value="" autocomplete=off>
<p><label for=name>name:</label><br>
<input tabindex=1 type="text" name="name" value="" placeholder="optional" autocomplete=off>
<p><label for=combos>combos:</label><br>
<input tabindex=1 type="text" name="combos" value="" placeholder="optional">
<p><span><label class=button for="peep">skip follow:
<input tabindex=1 type="checkbox" id="peep" name="peep" value="peep"><span></span></label></span>
<p><button tabindex=1 name="add honker" value="add honker">add honker</button>
</form>
</div>

View File

@ -4,25 +4,28 @@
<input type="hidden" name="CSRF" value="{{ .HonkCSRF }}">
<input type="hidden" name="updatexid" value = "{{ .UpdateXID }}">
<input type="hidden" name="rid" id="ridinput" value="{{ .InReplyTo }}">
<h3>let's make some noise</h3>
<p>
<details>
<summary>more options</summary>
<p>
<label id="donker">attach: {{ if .SavedFile }} {{ .SavedFile }} {{ else }} <input onchange="updatedonker();" type="file" name="donk"><span></span> {{ end }}</label>
<label class=button id="donker">attach: {{ if .SavedFile }} {{ .SavedFile }} {{ else }} <input onchange="updatedonker();" type="file" name="donk"><span></span> {{ end }}</label>
<input type="hidden" name="donkxid" value="{{ .SavedFile }}">
<p id="donkdescriptor">
desc: <input type="text" name="donkdesc" value="{{ .DonkDesc }}" autocomplete=off>
<p id="donkdescriptor"><label for=donkdesc>description:</label><br>
<input type="text" name="donkdesc" value="{{ .DonkDesc }}" autocomplete=off>
<p><button id=checkinbutton type=button onclick="fillcheckin()">checkin</button>
<div id=placedescriptor style="display: none">
<p>name: <input type="text" name="placename" id=placenameinput value="">
<p>url: <input type="text" name="placeurl" id=placeurlinput value="">
<p>lat: <input type="text" size=9 name="placelat" id=placelatinput value="">
lon: <input type="text" size=9 name="placelong" id=placelonginput value="">
<p><label>name:</label><br><input type="text" name="placename" id=placenameinput value="">
<p><label>url:</label><br><input type="text" name="placeurl" id=placeurlinput value="">
<p><label>lat: </label><input type="text" size=9 name="placelat" id=placelatinput value="">
<label>lon: </label><input type="text" size=9 name="placelong" id=placelonginput value="">
</div>
<p><button id=addtimebutton type=button onclick="showelement('timedescriptor')">add time</button>
<div id=timedescriptor style="display: none">
<p>start: <input type="text" name="timestart" value="">
<p>end: <input type="text" name="timeend" value="">
<p><label for=timestart>start:</label><br>
<input type="text" name="timestart" value="">
<p><label for=timeend>duration:</label><br>
<input type="text" name="timeend" value="">
</div>
</details>
<p>

View File

@ -99,7 +99,10 @@ main {
margin-top: 1em;
margin-bottom: 1em;
}
label, button, select {
label {
font-size: 1.0em;
}
label.button, button, select {
font-size: 16px;
font-family: monospace;
color: $fg;
@ -128,6 +131,12 @@ input[type="checkbox"] {
position: fixed;
top: -9999px;
}
.buttonarray {
line-height: 2.5em;
}
label.button {
white-space: nowrap;
}
input[type="checkbox"] + span:after {
content: "no";
}