2021-10-15 14:08:27 +00:00
|
|
|
{% for u in users %}
|
2021-12-01 23:28:59 +00:00
|
|
|
<div class="my-2 px-2 w-1/2 overflow-hidden lg:w-1/3 xl:w-1/5">
|
2021-10-15 14:08:27 +00:00
|
|
|
<div id="user-{{u.id}}" class="card h-100">
|
2021-12-01 23:28:11 +00:00
|
|
|
<div class="relative">
|
|
|
|
<img loading="lazy" src="{{u.banner_url}}" class="object-cover" alt="@{{u.username}} user banner" height=175>
|
2021-10-15 14:08:27 +00:00
|
|
|
|
2021-12-01 23:28:11 +00:00
|
|
|
<img loading="lazy" src="{{u.profile_url}}" class="profile-pic-50 border-3 border-white" style="position: absolute; left: 15px; bottom: 15px; box-sizing: content-box;">
|
|
|
|
</div>
|
2021-10-15 14:08:27 +00:00
|
|
|
|
2021-12-01 23:28:11 +00:00
|
|
|
<div class="card-body" style="word-wrap: break-word;">
|
|
|
|
<div class="d-flex flex-wrap justify-content-between align-items-center mb-3">
|
2021-10-15 14:08:27 +00:00
|
|
|
|
2021-12-01 23:28:11 +00:00
|
|
|
<a class="card-title text-break stretched-link h5 mb-0" href="{{u.url}}">@{{u.username}}</a>
|
2021-10-15 14:08:27 +00:00
|
|
|
|
2021-12-01 23:28:11 +00:00
|
|
|
{% if v %}
|
|
|
|
{% if v.id!=u.id and not u.is_private and not u.is_nofollow %}
|
|
|
|
<div id="button-sub-{{u.id}}" style="z-index: 2" class="{% if u.has_follower(v) %}d-none{% endif %}">
|
|
|
|
<button class="btn btn-green" onclick="post_toast2('/follow/{{u.username}}','button-sub-{{u.id}}','button-unsub-{{u.id}}')">Follow
|
|
|
|
</button>
|
2021-10-15 14:08:27 +00:00
|
|
|
</div>
|
|
|
|
|
2021-12-01 23:28:11 +00:00
|
|
|
{% if u.id != 995 %}
|
|
|
|
<div id="button-unsub-{{u.id}}" style="z-index: 2" class="{% if not u.has_follower(v) %} d-none{% endif %}">
|
|
|
|
<button class="btn btn-gray" onclick="post_toast2('/unfollow/{{u.username}}','button-sub-{{u.id}}','button-unsub-{{u.id}}')">Unfollow
|
|
|
|
</button
|
|
|
|
</div>
|
|
|
|
{% endif %}
|
|
|
|
{% endif %}
|
|
|
|
{% else %}
|
|
|
|
<div id="button-sub-{{u.id}}" style="z-index: 2">
|
|
|
|
<a class="btn btn-primary " href="/signup?redirect={{request.path}}">Follow
|
|
|
|
</a>
|
|
|
|
</div>
|
2021-10-15 14:08:27 +00:00
|
|
|
{% endif %}
|
|
|
|
</div>
|
2021-12-01 23:28:11 +00:00
|
|
|
|
|
|
|
{% if not hide_bios and u.bio_html %}
|
|
|
|
<div class="card-text">{{u.bio_html | safe}}</div>
|
|
|
|
{% endif %}
|
2021-10-15 14:08:27 +00:00
|
|
|
</div>
|
|
|
|
</div>
|
2021-12-01 23:28:11 +00:00
|
|
|
</div>
|
|
|
|
{% endfor %}
|