This repository has been archived on 2024-06-26. You can view files and clone it, but cannot push or open issues or pull requests.
sakura/resources/views/yuuno/settings/friends/listing.twig

40 lines
1.6 KiB
Twig
Raw Normal View History

2016-08-02 20:35:12 +00:00
{% extends 'settings/friends/master.twig' %}
{% set friends = user.friends(1)|batch(12) %}
{% set paginationPages = friends %}
{% set paginationUrl %}{{ route('settings.friends.listing') }}{% endset %}
{% set mode = 'Listing' %}
{% block description %}
<p>Manage your friends.</p>
{% endblock %}
{% block settingsContent %}
{% if friends|length %}
<div class="friends-list">
{% for friend in friends[get.page|default(1) - 1] %}
<div class="friend-container" id="friendslist-friend-{{ friend.id }}">
<a class="friends-list-data clean" href="{{ route('user.profile', friend.id) }}">
2016-09-13 22:05:03 +00:00
<img src="{{ route('user.avatar', friend.id) }}" alt="{{ friend.username }}" class="friends-list-avatar default-avatar-setting" style="width: 150px; height: 150px;">
<div class="friends-list-name" style="color: {{ friend.colour }};">{{ friend.username }}</div>
</a>
<div class="friends-list-actions">
2016-07-31 19:36:13 +00:00
<a class="remove fill fa fa-remove" title="Remove friend" href="javascript:void(0);" onclick="Sakura.Friend.Remove({{ friend.id }});"></a>
<div class="clear"></div>
</div>
</div>
{% endfor %}
<div class="clear"></div>
</div>
{% if friends|length > 1 %}
<div>
{% include 'elements/pagination.twig' %}
</div>
{% endif %}
{% else %}
<h1 class="stylised" style="margin: 2em auto; text-align: center;">You don't have any friends yet!</h1>
{% endif %}
{% endblock %}