2022-09-09 04:42:20 +00:00
|
|
|
<!-- User avatar widgets -->
|
|
|
|
|
2022-09-09 04:52:50 +00:00
|
|
|
<!-- Parameter: .User -->
|
|
|
|
{{define "avatar-24x24"}}
|
|
|
|
<figure class="image is-24x24 is-inline-block">
|
|
|
|
<a href="/u/{{.Username}}" class="has-text-dark">
|
|
|
|
{{if .ProfilePhoto.ID}}
|
2024-06-30 04:42:35 +00:00
|
|
|
{{if and (eq .ProfilePhoto.Visibility "private") (not .UserRelationship.IsPrivateGranted)}}
|
2022-09-09 04:52:50 +00:00
|
|
|
<img src="/static/img/shy-private.png" class="is-rounded">
|
2024-06-30 04:42:35 +00:00
|
|
|
{{else if and (eq .ProfilePhoto.Visibility "friends") (not .UserRelationship.IsFriend)}}
|
2022-09-09 04:52:50 +00:00
|
|
|
<img src="/static/img/shy-friends.png" class="is-rounded">
|
2024-06-30 04:42:35 +00:00
|
|
|
{{else if and (eq .ProfilePhoto.Visibility "circle") (not .UserRelationship.IsInnerCirclePeer)}}
|
2024-01-07 22:20:01 +00:00
|
|
|
<img src="/static/img/shy-secret.png">
|
2022-09-09 04:52:50 +00:00
|
|
|
{{else}}
|
|
|
|
<img src="{{PhotoURL .ProfilePhoto.CroppedFilename}}" class="is-rounded">
|
|
|
|
{{end}}
|
|
|
|
{{else}}
|
|
|
|
<img src="/static/img/shy.png" class="is-rounded">
|
|
|
|
{{end}}
|
|
|
|
</a>
|
|
|
|
</figure>
|
|
|
|
{{end}}
|
|
|
|
|
2022-09-09 04:42:20 +00:00
|
|
|
<!-- Parameter: .User -->
|
|
|
|
{{define "avatar-48x48"}}
|
|
|
|
<figure class="image is-48x48 is-inline-block">
|
|
|
|
<a href="/u/{{.Username}}" class="has-text-dark">
|
|
|
|
{{if .ProfilePhoto.ID}}
|
2024-06-30 04:42:35 +00:00
|
|
|
{{if and (eq .ProfilePhoto.Visibility "private") (not .UserRelationship.IsPrivateGranted)}}
|
2022-09-09 04:42:20 +00:00
|
|
|
<img src="/static/img/shy-private.png">
|
2024-06-30 04:42:35 +00:00
|
|
|
{{else if and (eq .ProfilePhoto.Visibility "friends") (not .UserRelationship.IsFriend)}}
|
2022-09-09 04:42:20 +00:00
|
|
|
<img src="/static/img/shy-friends.png">
|
2024-06-30 04:42:35 +00:00
|
|
|
{{else if and (eq .ProfilePhoto.Visibility "circle") (not .UserRelationship.IsInnerCirclePeer)}}
|
2024-01-07 22:20:01 +00:00
|
|
|
<img src="/static/img/shy-secret.png">
|
2022-09-09 04:42:20 +00:00
|
|
|
{{else}}
|
|
|
|
<img src="{{PhotoURL .ProfilePhoto.CroppedFilename}}">
|
|
|
|
{{end}}
|
|
|
|
{{else}}
|
|
|
|
<img src="/static/img/shy.png">
|
|
|
|
{{end}}
|
|
|
|
</a>
|
|
|
|
</figure>
|
|
|
|
{{end}}
|
|
|
|
|
|
|
|
<!-- Parameter: .User -->
|
|
|
|
{{define "avatar-64x64"}}
|
|
|
|
<figure class="image is-64x64 is-inline-block">
|
|
|
|
<a href="/u/{{.Username}}" class="has-text-dark">
|
|
|
|
{{if .ProfilePhoto.ID}}
|
2024-06-30 04:42:35 +00:00
|
|
|
{{if and (eq .ProfilePhoto.Visibility "private") (not .UserRelationship.IsPrivateGranted)}}
|
2022-09-09 04:42:20 +00:00
|
|
|
<img src="/static/img/shy-private.png">
|
2024-06-30 04:42:35 +00:00
|
|
|
{{else if and (eq .ProfilePhoto.Visibility "friends") (not .UserRelationship.IsFriend)}}
|
2022-09-09 04:42:20 +00:00
|
|
|
<img src="/static/img/shy-friends.png">
|
2024-06-30 04:42:35 +00:00
|
|
|
{{else if and (eq .ProfilePhoto.Visibility "circle") (not .UserRelationship.IsInnerCirclePeer)}}
|
2024-01-07 22:20:01 +00:00
|
|
|
<img src="/static/img/shy-secret.png">
|
2022-09-09 04:42:20 +00:00
|
|
|
{{else}}
|
|
|
|
<img src="{{PhotoURL .ProfilePhoto.CroppedFilename}}">
|
|
|
|
{{end}}
|
|
|
|
{{else}}
|
|
|
|
<img src="/static/img/shy.png">
|
|
|
|
{{end}}
|
|
|
|
</a>
|
|
|
|
</figure>
|
|
|
|
{{end}}
|
|
|
|
|
|
|
|
<!-- Parameter: .User -->
|
|
|
|
{{define "avatar-96x96"}}
|
|
|
|
<figure class="image is-96x96 is-inline-block">
|
|
|
|
<a href="/u/{{.Username}}" class="has-text-dark">
|
|
|
|
{{if .ProfilePhoto.ID}}
|
2024-06-30 04:42:35 +00:00
|
|
|
{{if and (eq .ProfilePhoto.Visibility "private") (not .UserRelationship.IsPrivateGranted)}}
|
2022-09-09 04:42:20 +00:00
|
|
|
<img src="/static/img/shy-private.png">
|
2024-06-30 04:42:35 +00:00
|
|
|
{{else if and (eq .ProfilePhoto.Visibility "friends") (not .UserRelationship.IsFriend)}}
|
2022-09-09 04:42:20 +00:00
|
|
|
<img src="/static/img/shy-friends.png">
|
2024-06-30 04:42:35 +00:00
|
|
|
{{else if and (eq .ProfilePhoto.Visibility "circle") (not .UserRelationship.IsInnerCirclePeer)}}
|
2024-01-07 22:20:01 +00:00
|
|
|
<img src="/static/img/shy-secret.png">
|
2022-09-09 04:42:20 +00:00
|
|
|
{{else}}
|
|
|
|
<img src="{{PhotoURL .ProfilePhoto.CroppedFilename}}">
|
|
|
|
{{end}}
|
|
|
|
{{else}}
|
|
|
|
<img src="/static/img/shy.png">
|
|
|
|
{{end}}
|
|
|
|
</a>
|
|
|
|
</figure>
|
|
|
|
{{end}}
|
|
|
|
|
|
|
|
<!-- Parameter: .User -->
|
|
|
|
{{define "avatar-32x32"}}
|
|
|
|
<figure class="image is-32x32 is-inline-block">
|
|
|
|
<a href="/u/{{.Username}}" class="has-text-dark">
|
|
|
|
{{if .ProfilePhoto.ID}}
|
2024-06-30 04:42:35 +00:00
|
|
|
{{if and (eq .ProfilePhoto.Visibility "private") (not .UserRelationship.IsPrivateGranted)}}
|
2022-09-09 04:42:20 +00:00
|
|
|
<img class="is-rounded" src="/static/img/shy-private.png">
|
2024-06-30 04:42:35 +00:00
|
|
|
{{else if and (eq .ProfilePhoto.Visibility "friends") (not .UserRelationship.IsFriend)}}
|
2022-09-09 04:42:20 +00:00
|
|
|
<img class="is-rounded" src="/static/img/shy-friends.png">
|
2024-06-30 04:42:35 +00:00
|
|
|
{{else if and (eq .ProfilePhoto.Visibility "circle") (not .UserRelationship.IsInnerCirclePeer)}}
|
2024-01-07 22:20:01 +00:00
|
|
|
<img src="/static/img/shy-secret.png">
|
2022-09-09 04:42:20 +00:00
|
|
|
{{else}}
|
|
|
|
<img class="is-rounded" src="{{PhotoURL .ProfilePhoto.CroppedFilename}}">
|
|
|
|
{{end}}
|
|
|
|
{{else}}
|
|
|
|
<img class="is-rounded" src="/static/img/shy.png">
|
|
|
|
{{end}}
|
|
|
|
</a>
|
|
|
|
</figure>
|
2023-10-23 07:04:25 +00:00
|
|
|
{{end}}
|