Admin fixes and improved OG meta support
This commit is contained in:
parent
1f54a6a6ac
commit
f560821be0
5 changed files with 51 additions and 19 deletions
|
@ -168,6 +168,26 @@
|
|||
|
||||
{% endmacro %}
|
||||
|
||||
{% macro display_og_meta(object) %}
|
||||
{% if object.og_meta %}
|
||||
{% for og_meta in object.og_meta %}
|
||||
<div style="display:flex;column-gap: 20px;margin:20px 0;">
|
||||
{% if og_meta.image %}
|
||||
<div>
|
||||
<img src="{{ og_meta.image | media_proxy_url }}" style="max-width:200px;">
|
||||
</div>
|
||||
<div>
|
||||
<a href="{{ og_meta.url }}">{{ og_meta.title }}</a>
|
||||
{% if og_meta.description %}<p>{{ og_meta.description }}</p>{% endif %}
|
||||
<small style="display:block;">{{ og_meta.site_name }}</small>
|
||||
</div>
|
||||
{% endif %}
|
||||
</div>
|
||||
{% endfor %}
|
||||
{% endif %}
|
||||
{% endmacro %}
|
||||
|
||||
|
||||
{% macro display_attachments(object) %}
|
||||
{% if object.attachments and object.sensitive and not request.query_params.show_sensitive == object.permalink_id %}
|
||||
{{ sensitive_button(object.permalink_id )}}
|
||||
|
@ -206,6 +226,8 @@
|
|||
</div>
|
||||
{% endif %}
|
||||
|
||||
{{ display_og_meta(object) }}
|
||||
|
||||
<a href="{{ object.url }}" class="u-url u-uid"><time class="dt-published" datetime="{{ object.ap_published_at }}">{{ object.ap_published_at | format_date }}</time></a>
|
||||
{{ object.visibility.value }}
|
||||
{% if object.is_from_outbox %}
|
||||
|
@ -248,8 +270,12 @@
|
|||
</div>
|
||||
</div>
|
||||
|
||||
<div style="padding-left:60px">
|
||||
{{ display_og_meta(object) }}
|
||||
</div>
|
||||
<div class="activity-attachment">
|
||||
{{ display_attachments(object) }}
|
||||
|
||||
{{ display_attachments(object) }}
|
||||
</div>
|
||||
|
||||
<div class="activity-bar">
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue