51 lines
1.7 KiB
HTML
51 lines
1.7 KiB
HTML
{% load static %}
|
|
{% load i18n %}
|
|
{% load l10n %}
|
|
{% load humanize %}
|
|
{% load mastodon %}
|
|
{% load thumb %}
|
|
{% load user_actions %}
|
|
{% load duration %}
|
|
{% for activity in activities %}
|
|
<section class="activity">
|
|
<div class="avatar">
|
|
<img src="{{ activity.owner.avatar }}" alt="cover">
|
|
</div>
|
|
<div>
|
|
<div>
|
|
<span class="time">
|
|
<span>{{ activity.action_object.created_time|naturaldelta }}</span>
|
|
</span>
|
|
<div class="spacing">
|
|
<span>
|
|
<a href="{{ activity.owner.url }}" class="nickname">{{ activity.owner.display_name }}</a>
|
|
</span>
|
|
<span>
|
|
<a href="{{ activity.owner.url }}" class="handler">@{{ activity.owner.full_handle }}</a>
|
|
</span>
|
|
</div>
|
|
{% with "activity/"|add:activity.template|add:".html" as template %}
|
|
{% include template %}
|
|
{% endwith %}
|
|
</div>
|
|
</div>
|
|
</section>
|
|
{% if forloop.last %}
|
|
<div class="htmx-indicator"
|
|
style="margin-left: 60px"
|
|
hx-get="{% url 'social:data' %}?last={{ activity.created_time|date:'Y-m-d H:i:s.uO'|urlencode }}"
|
|
hx-trigger="revealed"
|
|
hx-swap="outerHTML">
|
|
<i class="fa-solid fa-compact-disc fa-spin loading"></i>
|
|
</div>
|
|
{% endif %}
|
|
{% empty %}
|
|
{% if request.GET.last %}
|
|
<div class="empty">{% trans 'nothing more.' %}</div>
|
|
{% else %}
|
|
<div class="empty">
|
|
{% url 'users:data' as import_url %}
|
|
{% blocktrans %}Find and mark some books/movies/podcasts/games, <a href="{{ import_url }}">import your data</a> from Goodreads/Letterboxd/Douban, follow some fellow {{ site_name }} users on the fediverse, so their recent activities and yours will show up here.{% endblocktrans %}
|
|
</div>
|
|
{% endif %}
|
|
{% endfor %}
|