Fix duplication on project pages

Issue #26
This commit is contained in:
Oliver Davies 2016-06-07 22:13:07 +01:00
parent 7791277d55
commit 04c83f9c8b
9 changed files with 58 additions and 83 deletions

View file

@ -1,30 +1,18 @@
{% extends 'page' %}
{% block content_wrapper %}
<main class="col-md-9">
{{ page.blocks.content_top|raw }}
{{ page.blocks.content|raw }}
{{ page.blocks.content_bottom|raw }}
</main>
{% endblock %}
{% if page.image -%}
<img src="/assets/images/projects/{{ page.image.name ?: page.image }}" alt="{{ page.image.alt }}">
{%- endif %}
{% block content_top %}
{{ parent() }}
{% block content %}{% endblock %}
{% if page.image %}
<div class="project--image">
<img class="img-responsive" src="/assets/images/projects/{{ page.image }}" alt="The {{ page.title }} website.">
</div>
{% endif %}
{% endblock %}
{% block content_bottom %}
{% if page.website %}
<div class="project--website">
<a href="{{ page.website }}" class="btn btn-primary">View the website</a>
</div>
<a class="project__website" href="{{ page.website }}">
View the website
</a>
{% endif %}
{{ include('project-skills') }}
{{ include('project-company') }}
{{ include('projects/skills') }}
{{ include('projects/company') }}
{% endblock %}