|
1 | 1 | {#- jinja template: html/dashboard/app.jnj -#}
|
2 | 2 | {#
|
3 |
| -## Copyright (C) 2014-2015 Mag. Christian Tanzer All rights reserved |
| 3 | +## Copyright (C) 2014-2017 Mag. Christian Tanzer All rights reserved |
4 | 4 | ## Glasauergasse 32, A--1130 Wien, Austria. tanzer@swing.co.at
|
5 | 5 | ## #*** <License> ************************************************************
|
6 | 6 | ## This module is licensed under the terms of the BSD 3-Clause License
|
|
27 | 27 | ## 14-Jul-2014 (CT) Fix `{{ title }}` access in block `title`
|
28 | 28 | ## 3-Dec-2014 (CT) Adapt to changes in grid of pure-0.5.0
|
29 | 29 | ## 10-Jun-2015 (CT) Add `page_notifications` to display feedback from `/Auth`
|
| 30 | +## 4-Jan-2017 (CT) Use `html/base.m.jnj`, not home-grown code |
30 | 31 | ## ««revision-date»»···
|
31 | 32 | ##--
|
32 | 33 | #}
|
33 | 34 |
|
34 | 35 | {%- import (html_version or "html/5.jnj") as X -%}
|
35 | 36 | {%- import "html/page_notifications.m.jnj" as PN with context %}
|
36 | 37 | {%- import "html/media_fragments.jnj" as MF with context %}
|
| 38 | +{%- import "html/base.m.jnj" as BM with context %} |
| 39 | + |
37 | 40 | {%- import "html/dashboard/app.m.jnj" as DB with context %}
|
38 | 41 | {%- import "html/dashboard/edit.m.jnj" as DB_Edit with context %}
|
39 | 42 | {%- import "html/dashboard/user.m.jnj" as DB_User with context %}
|
40 | 43 | {%- import "html/dashboard/view.m.jnj" as DB_View with context %}
|
41 | 44 |
|
42 | 45 | {%- call X.html (lang = page.language|default ("en")) -%}
|
| 46 | + {%- set title = page.h_title or |
| 47 | + ("%s dashboard" % (page.owner or "<Owner is missing>", )) |
| 48 | + -%} |
43 | 49 | {%- call X.head () -%}
|
44 | 50 | {%- block head_elements -%}
|
45 |
| - {%- set title = page.h_title or |
46 |
| - ("%s dashboard" % (page.owner or "<Owner is missing>", )) |
47 |
| - -%} |
48 |
| - <meta charset="{{ page.encoding|default ("utf-8") }}" /> |
49 |
| - <meta name="viewport" content="width=device-width, initial-scale=1.0"> |
50 |
| - <meta name="description" content="{{ title }}"> |
51 |
| - {%- if page.exclude_robots %} |
52 |
| - <meta name="robots" content="NOINDEX, NOFOLLOW"> |
53 |
| - {% endif -%} |
| 51 | + {%- block meta_elements -%} |
| 52 | + {{ BM.meta_headers (page, description = title) }} |
| 53 | + {%- endblock meta_elements -%} |
| 54 | + {{ BM.link_rel_headers (page, template) }} |
54 | 55 | {% block head_base_element %}{% endblock head_base_element %}
|
55 | 56 | {% block title scoped %}
|
56 | 57 | <title>{{ title }}</title>
|
57 | 58 | {% endblock title -%}
|
58 | 59 | {%- block styles %}
|
59 |
| - {%- if template.css_href %} |
60 |
| - {{ X.link_stylesheet (template.css_href) }} |
61 |
| - {%- else %} |
62 |
| - {{ MF.inline_CSS (template.CSS) }} |
63 |
| - {% endif -%} |
64 |
| - {{ MF.link_css (template) }} |
| 60 | + {{ BM.style_headers (page, template) }} |
65 | 61 | {%- endblock styles %}
|
66 | 62 | {%- block scripts %}
|
67 | 63 | {{ MF.scripts (template) }}
|
68 | 64 | {%- endblock scripts -%}
|
69 |
| - {%- block meta_elements -%} |
70 |
| - <!-- copyright "{{ page.copyright.year }} {{ page.copyright.holder }}"--> |
71 |
| - <meta name="generator" content="GTW, JNJ, Jinja2" /> |
72 |
| - {%- endblock meta_elements -%} |
73 | 65 | {{ page.add_headers|safe }}
|
74 | 66 | {%- endblock head_elements %}
|
75 | 67 | {%- endcall %} {# X.head #}
|
|
0 commit comments