{% extends "admin_app.html" %} {% from "library.j2" import action_button, custom_form_button, form_button, circle_name %} {% block content %}

{% trans %}Manage circles{% endtrans %}

{% trans %}Circles aim to help people who are in the same social circle find each other on your service.{% endtrans %}

{% trans %}Users who are in the same circle will see each other in their contact list. In addition, each circle may have group chats where the circle members are included.{% endtrans %}

{%- if circles -%}
{{- invite_form.csrf_token -}}
{% for circle in circles %} {% endfor %}
{% trans %}Circle name{% endtrans %} {% trans %}Members{% endtrans %} {% trans %}Actions{% endtrans %}
{{ circle | circle_name }} {{ circle.members | length }} {%- call custom_form_button("create_link", invite_form.circles.name, circle.id_, slim=True, class="secondary accent") -%} {% trans circle_name=(circle | circle_name) %}Create invitation to circle {{ circle_name }}{% endtrans %} {%- endcall -%} {%- call action_button("people", url_for(".edit_circle", id_=circle.id_) + "#members", class="secondary") -%} {% trans circle_name=(circle | circle_name) %}Manage members of {{ circle_name }}{% endtrans %} {%- endcall -%} {%- call action_button("edit", url_for(".edit_circle", id_=circle.id_), class="primary") -%} {% trans circle_name=(circle | circle_name) %}Edit circle {{ circle_name }}{% endtrans %} {%- endcall -%}
{%- else -%}
{% trans %}No circles{% endtrans %}

{% trans %}Currently, there are no circles on this service. Use the form below to create one.{% endtrans %}

{%- endif -%}

{% trans %}New circle{% endtrans %}

{{- create_form.csrf_token -}}

{% trans %}Create circle{% endtrans %}

{{- create_form.name.label(class="required") -}} {{- create_form.name -}}
{%- call form_button("create_group", create_form.action_create, class="primary") -%}{%- endcall -%}
{% endblock %}