teasers: only show domain link for link posts

This commit is contained in:
rimu 2024-12-30 13:09:06 +13:00
parent 4d2ad699c8
commit 48d77d6d61

View file

@ -9,11 +9,13 @@
{% if post.type == POST_TYPE_VIDEO -%} {% if post.type == POST_TYPE_VIDEO -%}
<span class="fe fe-video" aria-hidden="true"></span> <span class="fe fe-video" aria-hidden="true"></span>
{% endif -%} {% endif -%}
<span class="domain_link" aria-hidden="true">(<a href="/d/{{ post.domain_id }}" aria-label="{{ _('All posts about this domain') }}">{{ post.domain.name }}</a>) {% if post.type == POST_TYPE_LINK -%}
{% if post.domain.post_warning -%} <span class="domain_link" aria-hidden="true">(<a href="/d/{{ post.domain_id }}" aria-label="{{ _('All posts about this domain') }}">{{ post.domain.name }}</a>)
<span class="fe fe-warning red" title="{{ post.domain.post_warning }}"></span> {% if post.domain.post_warning -%}
<span class="fe fe-warning red" title="{{ post.domain.post_warning }}"></span>
{% endif -%}
</span>
{% endif -%} {% endif -%}
</span>
{% endif -%} {% endif -%}
{% if post.nsfw -%}<span class="warning_badge nsfw" title="{{ _('Not safe for work') }}">nsfw</span>{% endif -%} {% if post.nsfw -%}<span class="warning_badge nsfw" title="{{ _('Not safe for work') }}">nsfw</span>{% endif -%}
{% if post.nsfl -%}<span class="warning_badge nsfl" title="{{ _('Potentially emotionally scarring content') }}">nsfl</span>{% endif -%} {% if post.nsfl -%}<span class="warning_badge nsfl" title="{{ _('Potentially emotionally scarring content') }}">nsfl</span>{% endif -%}