pyfedi/app/templates/index.html

73 lines
2.9 KiB
HTML
Raw Normal View History

{% extends "base.html" %}
{% from 'bootstrap5/form.html' import render_form %}
{% block app_content %}
<div class="row">
<div class="col-12 col-md-8 position-relative main_pane">
2024-01-02 23:14:39 -08:00
{% include "_home_nav.html" %}
<div class="post_list">
{% for post in posts %}
{% include 'post/_post_teaser.html' %}
{% else %}
<p>{{ _('No posts yet. Join some communities to see more.') }}</p>
2024-01-04 15:08:30 -08:00
<p><a class="btn btn-primary" href="/communities">{{ _('Explore communities') }}</a></p>
{% endfor %}
</div>
<nav aria-label="Pagination" class="mt-4">
{% if prev_url %}
2024-01-02 23:14:39 -08:00
<a href="{{ prev_url }}" class="btn btn-primary" rel="nofollow">
<span aria-hidden="true">&larr;</span> {{ _('Previous page') }}
</a>
{% endif %}
{% if next_url %}
2024-01-02 23:14:39 -08:00
<a href="{{ next_url }}" class="btn btn-primary" rel="nofollow">
{{ _('Next page') }} <span aria-hidden="true">&rarr;</span>
</a>
{% endif %}
</nav>
</div>
2024-01-04 01:21:31 -08:00
<div class="col-12 col-md-4 side_pane">
<!-- <div class="card">
<div class="card-body">
<form method="get">
<input type="search" name="search" class="form-control mt-2" placeholder="{{ _('Search') }}" />
</form>
</div>
</div> -->
<div class="card mt-3">
<div class="card-header">
<h2>{{ _('Active communities') }}</h2>
</div>
<div class="card-body">
<ul class="list-group list-group-flush">
{% for community in active_communities %}
<li class="list-group-item">
2023-12-30 15:09:20 -08:00
<a href="/c/{{ community.link() }}"><img src="{{ community.icon_image() }}" class="community_icon rounded-circle" loading="lazy" />
{{ community.display_name() }}
</a>
</li>
{% endfor %}
</ul>
2024-01-04 15:08:30 -08:00
<p class="mt-4"><a class="btn btn-primary" href="/communities">{{ _('Explore communities') }}</a></p>
</div>
</div>
<div class="card mt-3">
<div class="card-header">
<h2>{{ _('About %(site_name)s', site_name=g.site.name) }}</h2>
</div>
<div class="card-body">
<p><strong>{{ g.site.description|safe }}</strong></p>
<p>{{ g.site.sidebar|safe }}</p>
<p class="mt-4">
<a class="no-underline" href="{{ rss_feed }}" rel="nofollow"><span class="fe fe-rss"></span> RSS feed</a>
</p>
</div>
</div>
</div>
</div>
{% endblock %}