Updated project layout

This commit is contained in:
Oliver Davies 2016-02-06 21:01:55 +00:00
parent 7ee5418053
commit 010e9b5867

View file

@ -11,17 +11,9 @@
{% block content_top %} {% block content_top %}
{{ parent() }} {{ parent() }}
Role: {{ page.role }} {% if page.image %}
<div class="project--image">
{% if page.company %} <img class="img-responsive" src="/assets/images/projects/{{ page.image }}" alt="The {{ page.title }} website.">
<div class="project--company">
<em>{% spaceless %}{% set company = site.companies[page.company] %}
Developed on behalf of
{% if company.website %}
<a href="{{ company.website }}">{{ company.title }}</a>
{% else %}
{{ company.title }}
{% endif %}{% endspaceless %}.</em>
</div> </div>
{% endif %} {% endif %}
{% endblock %} {% endblock %}
@ -33,9 +25,29 @@
</div> </div>
{% endif %} {% endif %}
{% if page.image %} {% if page.company %}
<div class="project--image"> {% set company = site.companies[page.company] %}
<img src="/assets/images/projects/{{ page.image }}" alt="The {{ page.title }} website.">
<div class="project--company{% if company.logo %} project--company__has-logo{% endif %}">
{% if page.freelance %}
<h2>Built for</h2>
{% else %}
<h2>Built whilst at</h2>
{% endif %}
{% if company.logo %}
{% set name = '<img src="/assets/images/experience/' ~ company.logo ~ '" alt="' ~ company.title ~ '">' %}
{% else %}
{% set name = company.title %}
{% endif %}
{% if company.website %}
<a href="{{ company.website }}" title="{{ company.title }}">
{{ name|raw }}
</a>
{% else %}
{{ name|raw }}
{% endif %}
</div> </div>
{% endif %} {% endif %}
{% endblock %} {% endblock %}