55 lines
1.6 KiB
Twig
55 lines
1.6 KiB
Twig
<!DOCTYPE html>
|
|
<html lang="en">
|
|
<head>
|
|
<meta charset="utf-8"/>
|
|
<title>{% block title %}Untitled page{% endblock %} - {{ app_info.getTitle() }}</title>
|
|
<meta name="viewport" content="width=device-width, initial-scale=1"/>
|
|
<link rel="stylesheet" href="/static/style.css"/>
|
|
</head>
|
|
|
|
<body>
|
|
|
|
<header>
|
|
<h1>{{ app_info.getTitle() }}</h1>
|
|
<div class="header_appversion">
|
|
{% if logged_in | default() %}
|
|
<a href="{{ app_info.getRepositoryUrl() }}">{{ app_info.getVersion() }}</a>
|
|
{% else %}
|
|
{{ app_info.getVersion() }}
|
|
{% endif %}
|
|
</div>
|
|
<div class="header_spacer"></div>
|
|
<div class="header_userstatus">
|
|
{% if logged_in | default() %}
|
|
Hello, <b>{{ current_user_name }}</b>. | <a href="/logout">Logout</a>
|
|
{% else %}
|
|
<a href="/login">Login</a>
|
|
{% endif %}
|
|
</div>
|
|
</header>
|
|
|
|
{% if logged_in | default() %}
|
|
<nav>
|
|
<ul>
|
|
{% macro navbar_item(path, text) -%}
|
|
<li{% if current_url() == path or current_url() starts with path ~ '/' %} class="nav_current_page"{% endif %}>
|
|
<a href="{{ path }}">{{ text }}</a>
|
|
</li>
|
|
{%- endmacro -%}
|
|
|
|
{{ _self.navbar_item('/', 'Dashboard') }}
|
|
{{ _self.navbar_item('/domains', 'Domains') }}
|
|
{{ _self.navbar_item('/accounts', 'Accounts') }}
|
|
</ul>
|
|
</nav>
|
|
{% endif %}
|
|
|
|
<main{% if main_classes is defined %} class="{{ main_classes }}"{% endif %}>
|
|
{% block content %}
|
|
Nothing to see here...
|
|
{% endblock %}
|
|
</main>
|
|
|
|
</body>
|
|
</html>
|