summaryrefslogtreecommitdiff
path: root/resources/views/layouts/app.twig
diff options
context:
space:
mode:
Diffstat (limited to 'resources/views/layouts/app.twig')
-rw-r--r--resources/views/layouts/app.twig48
1 files changed, 48 insertions, 0 deletions
diff --git a/resources/views/layouts/app.twig b/resources/views/layouts/app.twig
new file mode 100644
index 00000000..d8f8d10f
--- /dev/null
+++ b/resources/views/layouts/app.twig
@@ -0,0 +1,48 @@
+{% set theme = user.color|default(config('theme')) %}
+<!DOCTYPE html>
+<html lang="{{ session_get('locale')|split('_')[0]|escape('html_attr') }}">
+<head>
+ {% block head %}
+ <title>{% block title %}{{ title }}{% endblock %} - Engelsystem</title>
+
+ <meta charset="UTF-8"/>
+ <meta name="viewport" content="width=device-width, initial-scale=1">
+
+ <link rel="stylesheet" type="text/css" href="{{ asset('assets/theme' ~ theme ~ '.css') }}"/>
+ <script type="text/javascript" src="{{ asset('assets/vendor.js') }}"></script>
+
+ {% if page() in ['news', 'user-meetings', '/'] and is_user() -%}
+ {% set parameters = {'key': user.api_key} -%}
+ {% if page() == 'user-meetings' -%}
+ {% set parameters = parameters|merge({'meetings': 1}) -%}
+ {% endif %}
+ <link href="{{ url('atom', parameters) }}" type="application/atom+xml" rel="alternate" title="Atom Feed">
+ {% endif %}
+
+ {% endblock %}
+</head>
+<body>
+
+{% block body %}
+ {% block header %}
+ {% include "layouts/parts/navbar.twig" %}
+ {% endblock %}
+
+ <div class="container-fluid">
+ <div class="row" id="content">
+ {% block content %}
+ {{ content|raw }}
+ {% endblock %}
+ </div>
+ <div class="row" id="footer">
+ {% block footer %}
+ {% include "layouts/parts/footer.twig" %}
+ {% endblock %}
+ </div>
+ </div>
+
+ {% block scripts %}{% endblock %}
+{% endblock %}
+
+</body>
+</html>