flash.moe/templates/dev/projects.twig

42 lines
1.7 KiB
Twig

{% extends 'dev/master.twig' %}
{% set header_title = 'projects' %}
{% set master_breadcrumbs = [{ url: '/projects', text: 'projects' }] %}
{% block column_centre %}
{% for project in projects %}
<div class="project" id="{{ project.info.cleanName }}" style="--project-colour: {{ project.colour }};">
<h2>{{ project.info.name }}</h2>
{% if project.info.hasSummary %}
<p>{{ project.info.summary }}</p>
{% endif %}
{% if project.info.hasDescription %}
{% set lines = project.info.description|split("\n") %}
{% for line in lines %}
<p>{{ line|trim }}</p>
{% endfor %}
{% endif %}
<div class="project-tags">
{% for lang in project.langs %}
<span class="project-tag" style="--tag-colour: {{ lang.colour }};">{{ lang.name }}</span>
{% endfor %}
{% if project.info.hasHomePageUrl %}
<a class="project-tag project-tag-link" href="{{ project.info.homePageUrl }}" rel="noopener" target="_blank">Homepage</a>
{% endif %}
{% if project.info.hasSourceUrl %}
<a class="project-tag project-tag-link" href="{{ project.info.sourceUrl }}" rel="noopener" target="_blank">Source</a>
{% endif %}
{% if project.info.hasDiscussionUrl %}
<a class="project-tag project-tag-link" href="{{ project.info.discussionUrl }}" rel="noopener" target="_blank">Discussion</a>
{% endif %}
</div>
</div>
{% endfor %}
{% endblock %}