add: "all" timeline
add: only show most popular posts from the past week
This commit is contained in:
parent
fc9c0f294e
commit
24f67221ca
13 changed files with 143 additions and 27 deletions
20
crates/app/src/public/html/timelines/all.html
Normal file
20
crates/app/src/public/html/timelines/all.html
Normal file
|
@ -0,0 +1,20 @@
|
|||
{% extends "root.html" %} {% block head %}
|
||||
<title>Latest posts - {{ config.name }}</title>
|
||||
{% endblock %} {% block body %} {{ macros::nav() }}
|
||||
<main class="flex flex-col gap-2">
|
||||
{{ macros::timelines_nav(selected="all") }}
|
||||
|
||||
<!-- prettier-ignore -->
|
||||
<div class="card w-full flex flex-col gap-2">
|
||||
{% for post in list %}
|
||||
{% if post[0].context.repost and post[0].context.repost.reposting %}
|
||||
{{ components::repost(repost=post[3], post=post[0], owner=post[1], secondary=true, community=post[2], show_community=true) }}
|
||||
{% else %}
|
||||
{{ components::post(post=post[0], owner=post[1], secondary=true, community=post[2]) }}
|
||||
{% endif %}
|
||||
{% endfor %}
|
||||
|
||||
{{ components::pagination(page=page, items=list|length) }}
|
||||
</div>
|
||||
</main>
|
||||
{% endblock %}
|
Loading…
Add table
Add a link
Reference in a new issue