indicate received honks that aren't fully public

This commit is contained in:
Ted Unangst 2019-04-28 18:41:10 -04:00
parent 46cc488d19
commit 27980a7dca
4 changed files with 13 additions and 1 deletions

7
fun.go
View File

@ -50,6 +50,13 @@ func reverbolate(honks []*Honk) {
h.URL = h.XID h.URL = h.XID
} }
} }
h.Privacy = "limited"
for _, a := range h.Audience {
if a == thewholeworld {
h.Privacy = ""
break
}
}
zap := make(map[*Donk]bool) zap := make(map[*Donk]bool)
h.Noise = unpucker(h.Noise) h.Noise = unpucker(h.Noise)
h.HTML = cleanstring(h.Noise) h.HTML = cleanstring(h.Noise)

View File

@ -61,6 +61,7 @@ type Honk struct {
Noise string Noise string
Convoy string Convoy string
Audience []string Audience []string
Privacy string
HTML template.HTML HTML template.HTML
Donks []*Donk Donks []*Donk
} }

View File

@ -1,4 +1,4 @@
<div class="honk {{ .Honk.What }}"> <div class="honk {{ .Honk.What }} {{ .Honk.Privacy }}">
{{ with .Honk }} {{ with .Honk }}
<div class="title"> <div class="title">
<img alt="avatar" src="/a?a={{ .Honker}}"> <img alt="avatar" src="/a?a={{ .Honker}}">

View File

@ -150,6 +150,10 @@ button a {
.zonked .noise a { .zonked .noise a {
color: #a79; color: #a79;
} }
.limited {
border: 1px solid #f04;
color: #a79;
}
.inlineform { .inlineform {
display: inline; display: inline;
} }