{% extends "semantic-ui/invenio_communities/details/header.html" %}
{% from "semantic-ui/invenio_communities/details/header.html" import button_for_membership with context %}
{%- block subheader_buttons %}
{{ button_for_membership(community_ui) }}
{# oarepo-communities: link to the (otherwise unreachable) create-subcommunity page.
Guarded by children.allow on this (parent) community and by the same `create`
permission the communities_new_subcommunity view enforces (exposed as the
can_create_community template global). #}
{% if community_ui['children'] and community_ui['children']['allow'] and can_create_community() %}
{{ _("Add sub-community") }}
{% endif %}
{%- if not community_use_jinja_header %}
{%- if not permissions.can_submit_record %}