27 lines
1.3 KiB
HTML
27 lines
1.3 KiB
HTML
{#
|
|
The section switcher shared by the three permission pages. Every one of them
|
|
carries a `page.tabs` (crate::pages::permissions::common::state::Tabs), which
|
|
says which section is open and which the signed-in role may open at all.
|
|
|
|
The three are deliberately separate pages: making a role, handing it to
|
|
someone, and deciding what it may do are three different decisions, and doing
|
|
them on one screen was what made the old page hard to read.
|
|
#}
|
|
<nav class="tabs" aria-label="permission sections">
|
|
{% if page.tabs.can_manage_roles %}
|
|
<a href="/permissions/roles" class="tab {% if page.tabs.is("roles") %}selected{% endif %}" {% if page.tabs.is("roles") %}aria-current="page"{% endif %}>
|
|
<span>Roles</span><small>Create roles and their inheritance</small>
|
|
</a>
|
|
{% endif %}
|
|
{% if page.tabs.can_manage_users %}
|
|
<a href="/permissions/users" class="tab {% if page.tabs.is("users") %}selected{% endif %}" {% if page.tabs.is("users") %}aria-current="page"{% endif %}>
|
|
<span>People</span><small>Give a user a role</small>
|
|
</a>
|
|
{% endif %}
|
|
{% if page.tabs.can_manage_roles %}
|
|
<a href="/permissions/grants" class="tab {% if page.tabs.is("grants") %}selected{% endif %}" {% if page.tabs.is("grants") %}aria-current="page"{% endif %}>
|
|
<span>Access</span><small>What a role may do</small>
|
|
</a>
|
|
{% endif %}
|
|
</nav>
|