gnu-social/plugins/Embed/templates/embed/embedView.html.twig
Diogo Peralta Cordeiro 9e4cac0123
[ENTITY] Refactor RemoteURL entities to Link
RemoteURL was being an awfully confusing term.
2021-09-14 13:13:26 +01:00

33 lines
1.4 KiB
Twig

<article class="h-entry embed">
<header>
{% if attributes != false %}
<img class="u-photo embed" width="{{attributes['width']}}" height="{{attributes['height']}}" src="{{attributes['src']}}" />
{% endif %}
<h5 class="p-name embed">
<a class="u-url" href="{{link.getUrl()}}">{{embed.getTitle() | escape}}</a>
</h5>
<div class="p-author embed">
{% if embed.getAuthorName() is not null %}
<div class="fn vcard author">
{% if embed.getAuthorUrl() is null %}
<p>{{embed.getAuthorName()}}</p>
{% else %}
<a href="{{embed.getAuthorUrl()}}" class="url">{{embed.getAuthorName()}}</a>
{% endif %}
</div>
{% endif %}
{% if embed.getProviderName() is not null %}
<div class="fn vcard">
{% if embed.getProviderUrl() is null %}
<p>{{embed.getProviderName()}}</p>
{% else %}
<a href="{{embed.getProviderUrl()}}" class="url">{{embed.getProviderName()}}</a>
{% endif %}
</div>
{% endif %}
</div>
</header>
<div class="p-summary embed">
{{ embed.getHtml() | escape }}
</div>
</article>