externalise header - add support for image
This commit is contained in:
parent
646ca39aaf
commit
cc4b6388fd
5 changed files with 11 additions and 25 deletions
|
@ -11,12 +11,7 @@
|
|||
{% endblock %}
|
||||
|
||||
{% block content %}
|
||||
<section class="bg-primary">
|
||||
<div class="container text-center text-uppercase">
|
||||
<h1 class="section-heading uppercase">{{ article.title }}</h1>
|
||||
<hr class="light">
|
||||
</div>
|
||||
</section>
|
||||
{% include 'extras/header.html' with context %}
|
||||
<section>
|
||||
<div class="container">
|
||||
{{ article.content }}
|
||||
|
|
|
@ -11,12 +11,7 @@
|
|||
{% endblock %}
|
||||
|
||||
{% block content %}
|
||||
<section class="bg-primary">
|
||||
<div class="container text-center text-uppercase">
|
||||
<h1 class="section-heading uppercase">{{ article.title }}</h1>
|
||||
<hr class="light">
|
||||
</div>
|
||||
</section>
|
||||
{% include 'extras/header.html' with context %}
|
||||
<section>
|
||||
<div class="container">
|
||||
<p class="text-right small">
|
||||
|
|
6
theme/templates/extras/header.html
Normal file
6
theme/templates/extras/header.html
Normal file
|
@ -0,0 +1,6 @@
|
|||
<section id="header" class="bg-primary image" data-image="{{ article.image if article else page.image }}">
|
||||
<div class="container text-center text-uppercase">
|
||||
<h1 class="section-heading">{{ article.title if article else page.title }}</h1>
|
||||
<hr class="light">
|
||||
</div>
|
||||
</section>
|
|
@ -12,12 +12,7 @@
|
|||
|
||||
{% block content %}
|
||||
{% if not page.no_container %}
|
||||
<section class="bg-primary">
|
||||
<div class="container text-center text-uppercase">
|
||||
<h1 class="section-heading uppercase">{{ page.title }}</h1>
|
||||
<hr class="light">
|
||||
</div>
|
||||
</section>
|
||||
{% include 'extras/header.html' with context %}
|
||||
<section>
|
||||
<div class="container">
|
||||
{{ page.content }}
|
||||
|
|
|
@ -11,12 +11,7 @@
|
|||
{% endblock %}
|
||||
|
||||
{% block content %}
|
||||
<section class="bg-primary">
|
||||
<div class="container text-center text-uppercase">
|
||||
<h1 class="section-heading uppercase">{{ article.title }}</h1>
|
||||
<hr class="light">
|
||||
</div>
|
||||
</section>
|
||||
{% include 'extras/header.html' with context %}
|
||||
<section>
|
||||
<div class="container">
|
||||
<p class="text-right small">
|
||||
|
|
Reference in a new issue