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

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

{% endif %} {% endblock %}
{% 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": "#organization-info", "post": h.url_for('organization.unfollow', id=organization.id)}, _extra_class="nsw-width-100") }} {% else %} {{ ui.button(_("Follow"), icon="bell", style="secondary", hx={"target": "#organization-info", "post": h.url_for('organization.follow', id=organization.id)}, _extra_class="nsw-width-100") }} {%- endif -%} {% endblock %}
{% endif %} {% if show_nums %} {% block nums %} {% set num_followers = h.follow_count('group', organization.id) %} {%- call ui.util.call(ui.table, striped=true, condensed=true, adaptive=true, _extra_class="profile-nums") -%} {{ _('Followers') }} {{ h.SI_number_span(num_followers) }} {{ h.humanize_entity_type('package', dataset_type, 'facet label') or _('Datasets') }} {{ h.SI_number_span(organization.package_count) }} {{ _('Members') }} {{ h.member_count(organization.id) }} {%- endcall -%} {% endblock %} {% endif %} {%- endblock -%} {%- endcall %} {%- endblock %}