mirror of
https://git.sr.ht/~tsileo/microblog.pub
synced 2024-11-15 03:04:28 +00:00
Add support for audio attachment
This commit is contained in:
parent
972e129381
commit
9432128540
1 changed files with 4 additions and 1 deletions
|
@ -185,6 +185,8 @@
|
|||
<a href="{{ a.url | get_attachment_url(None) }}"><img src="{{a.url | get_attachment_url(720) }}" class="img-attachment"></a>
|
||||
{% elif (a.mediaType and a.mediaType.startswith("video/")) %}
|
||||
<li><video controls preload="metadata" src="{{ a.url | get_attachment_url(None) }}" width="480"></video></li>
|
||||
{% elif (a.mediaType and a.mediaType.startswith("audio/")) %}
|
||||
<li><audio controls preload="metadata" src="{{ a.url | get_attachment_url(None) }}"></audio></li>
|
||||
{% else %}
|
||||
<li><a href="{{a.url }}" class="l">{% if a.filename %}{{ a.filename }}{% else %}{{ a.url }}{% endif %}</a></li>
|
||||
{% endif %}
|
||||
|
@ -320,7 +322,8 @@
|
|||
<input type="hidden" name="csrf_token" value="{{ csrf_token() }}">
|
||||
<button type="submit" class="bar-item" onclick="return confirm('Confirm the block action?');">block</button>
|
||||
</form>
|
||||
{% endif %}
|
||||
<!--<a class="bar-item" href="/admin/profile?id={{actor.id}}">profile</a>
|
||||
-->{% endif %}
|
||||
|
||||
{% endif %}
|
||||
|
||||
|
|
Loading…
Reference in a new issue