{% extends "tungsten/layout/base.html" %} {% import "tungsten/components/ui.html" as ui %} {% block body %}
{# ------------------------------------------------------------ sidebar #}
{# ------------------------------------------------------------ main #}
{% if panel.top_navigation %} {% if tenants or tenant_menu %}{% endif %} {% include "tungsten/components/top-navigation.html" %} {% elif panel.sidebar_collapsible %} {% endif %} {{ panel.hooks('topbar.start', ctx) }} {% if panel.global_search_enabled %} {% include "tungsten/components/global-search.html" %} {% endif %}
{{ panel.hooks('topbar.end', ctx) }} {% if panel.dark_mode %} {% endif %} {% if user and panel.database_notifications %} {% include "tungsten/components/notification-bell.html" %} {% endif %} {% if user and panel.notifications_live %} {% endif %} {% if user %} {% call(part) ui.dropdown(width='w-60') %} {% if part == 'trigger' %} {% else %}

{{ user_name }}

{{ user | attr(panel.auth.email_field) or '' }}

{% if panel.auth.profile %}{{ icon('user', 'h-4 w-4') }}{{ __('My profile') }}{% endif %} {% for item in user_menu_items %}{{ icon(item.icon, 'h-4 w-4') }}{{ __(item.label) }}{% endfor %} {{ panel.hooks('user-menu.items', ctx) }}
{% if panel.locales | length > 1 %}

{{ icon('languages', 'h-3.5 w-3.5') }}{{ __('Language') }}

{% for lang in panel.language_options() %}
{% endfor %}
{% endif %}
{% endif %} {% endcall %} {% endif %}
{{ panel.hooks('content.start', ctx) }} {% set sub_navigation = panel.sub_navigation(ctx, resource=resource if resource is defined else none, record=record if record is defined else none, page=page if page is defined else none) %} {% if sub_navigation %} {% set sub_position = sub_navigation.position %}
{% if sub_position == 'top' %} {% else %} {% endif %}
{{ self.content() }}
{% else %} {% block content %}{% endblock %} {% endif %} {{ panel.hooks('content.end', ctx) }}
{% endblock %}