{% set dataset_type = h.default_package_type() %} {% block info %} {%- call ui.util.call(ui.sidebar_section, title=_("Details"), attrs={"id": "group-info"}) -%} {% block inner %} {% block image %}
{{ ui.image(src=group.image_display_url or h.url_for_static('/base/images/placeholder-group.svg'), alt=group.display_name) }}
{% endblock %}
{% block heading %} {{ group.display_name }} {% if group.state == 'deleted' %} [{{ _('Deleted') }}] {% endif %} {%- endblock -%}
{% block description %} {% if group.description %}

{{ h.markdown_extract(group.description, 180) }}

{% endif %} {% endblock %}
{% if show_nums %} {% if current_user.is_authenticated %}
{% block follow %} {{ ui.alert(error_message, style="danger") if error_message }} {% if am_following %} {{ ui.button(_("Unfollow"), icon="bell-slash", style="secondary", hx={"target": "#group-info", "post": h.url_for('group.unfollow', id=group.id)}, full=true) }} {% else %} {{ ui.button(_("Follow"), icon="bell", style="secondary", hx={"target": "#group-info", "post": h.url_for('group.follow', id=group.id)}, full=true) }} {%- endif -%} {% endblock %}
{% endif %} {% block nums %} {% set num_followers = h.follow_count('group', group.id) %} {%- call ui.util.call(ui.table, striped=true, condensed=true, adaptive=true) -%} {{ _('Followers') }} {{ h.SI_number_span(num_followers) }} {{ h.humanize_entity_type('package', dataset_type, 'facet label') or _('Datasets') }} {{ h.SI_number_span(group.package_count) }} {{ _('Members') }} {{ h.member_count(group.id) }} {%- endcall %} {% endblock %} {% endif %} {% endblock %} {%- endcall %} {% endblock %}