mirror of
https://git.freesoftwareextremist.com/bloat
synced 2024-12-22 17:10:42 +00:00
Add attachment media support
This commit is contained in:
parent
5e4da01c3a
commit
55d559552c
1 changed files with 21 additions and 0 deletions
|
@ -8,6 +8,27 @@
|
|||
<span class="status-uname"> {{.Account.Acct}} </span>
|
||||
</div>
|
||||
<div class="status-content"> {{WithEmojis .Content .Emojis}} </div>
|
||||
<div class="status-media-container">
|
||||
{{range .MediaAttachments}}
|
||||
{{if eq .Type "image"}}
|
||||
<a href="{{.URL}}" target="_blank">
|
||||
<img class="status-image" src="{{.URL}}" alt="status-image" />
|
||||
</a>
|
||||
{{else if eq .Type "audio"}}
|
||||
<audio class="status-audio" controls preload="none">
|
||||
<source src="{{.URL}}">
|
||||
<p> Your browser doesn't support HTML5 audio </p>
|
||||
</audio>
|
||||
{{else if eq .Type "video"}}
|
||||
<video class="status-video" controls preload="none">
|
||||
<source src="{{.URL}}">
|
||||
<p> Your browser doesn't support HTML5 video </p>
|
||||
</video>
|
||||
{{else}}
|
||||
<a href="{{.URL}}" target="_blank"> attachment </a>
|
||||
{{end}}
|
||||
{{end}}
|
||||
</div>
|
||||
<div class="status-action">
|
||||
<a class="status-you" href="/thread/{{.ID}}?reply=true" title="reply">
|
||||
<span class="icon dripicons-reply"></span>
|
||||
|
|
Loading…
Reference in a new issue